TarsCloud / TarsCpp

C++ language framework rpc source code implementation
BSD 3-Clause "New" or "Revised" License
523 stars 254 forks source link

[MSVC][std:c++latest] Fix compiler error #256

Closed QuellaZhang closed 2 years ago

QuellaZhang commented 2 years ago

When building TarsCpp with /std:c++latest on MSVC, we got the following errors, now fix it. See https://godbolt.org/z/6chsKhYEc.

F:\gitP\TarsCloud\TarsCpp\util\src\tc_strptime.cpp(113,22): error C2059: syntax error: '!' [F:\gitP\TarsCloud\TarsCpp\build_amd64\util\src\tarsutil.vcxproj] F:\gitP\TarsCloud\TarsCpp\util\src\tc_strptime.cpp(113,36): error C2143: syntax error: missing ';' before '}' [F:\gitP\TarsCloud\TarsCpp\build_amd64\util\src\tarsutil.vcxproj] F:\gitP\TarsCloud\TarsCpp\util\src\tc_strptime.cpp(113,36): error C2059: syntax error: '}' [F:\gitP\TarsCloud\TarsCpp\build_amd64\util\src\tarsutil.vcxproj] F:\gitP\TarsCloud\TarsCpp\util\src\tc_strptime.cpp(201,33): error C2065: 'loc': undeclared identifier [F:\gitP\TarsCloud\TarsCpp\build_amd64\util\src\tarsutil.vcxproj] F:\gitP\TarsCloud\TarsCpp\util\src\tc_strptime.cpp(205,32): error C2065: 'raw': undeclared identifier [F:\gitP\TarsCloud\TarsCpp\build_amd64\util\src\tarsutil.vcxproj] F:\gitP\TarsCloud\TarsCpp\util\src\tc_strptime.cpp(224,32): error C2065: 'raw': undeclared identifier [F:\gitP\TarsCloud\TarsCpp\build_amd64\util\src\tarsutil.vcxproj] F:\gitP\TarsCloud\TarsCpp\util\src\tc_strptime.cpp(522,15): error C2065: 'raw': undeclared identifier [F:\gitP\TarsCloud\TarsCpp\build_amd64\util\src\tarsutil.vcxproj]