Open qq316387171 opened 5 months ago
using namespace std;
int main() { string str = "111222"; MessageBoxA(0,str.data(),0,0): return 0; }
cl /c main.cpp /EHsc /std:c++14
In file included from C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.33.31629\include\cstddef:13:
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.33.31629\include\xtr1common(180,5) : error:
use of undeclared identifier 'char16_t'
180 | char16_t, char32_t, short, unsigned short, int, unsigned int, long, unsigned long, long long, unsigned long long>;
| ^
In file included from main.cpp:3:
In file included from C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.33.31629\include\string:11:
In file included from C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.33.31629\include\xstring:13:
C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.33.31629\include\iosfwd(158,20) : error:
use of undeclared identifier 'char16_t'
158 | struct char_traits
include
include
using namespace std;
After using string, compilation error is reported error: use of undeclared identifier 'char16_t