I use Ubuntu 18.04 and gcc 7.5.0. I have a library which is compiled with -fshort-wchar. I have noticed that using std::wstring
in the library may leads to the segmentation fault. I have found a similar topic. There is an explanation:
-fshort-wchar is not usable if you want to interact with any part of the standard library or third-party library code using the correct (32-bit) definition of wchar_t.
I understand that I can't use std::wstring
when a library is compiled with -fshort-wchar
but what with the other standard library content ? Why I can't interact with any part of the standard library, for example std::vector ?