cppast
cppast copied to clipboard
MSVC Compilation error
- cppast version: 55221f1536a1f21c3f0b0b4dbb28344185ec655c
- parser:
libclang_parser - clang version: 8.0
Can't compile cppast using MS VC++ compiler versions: 19.16, 19.21, 19.22.
Input flags:
cmake -B build -S. -GNinja -DCMAKE_BUILD_TYPE=Release -DLIBCLANG_LIBRARY=F:\llvm8\lib\libclang.lib
Output:
\cppast\external\type_safe\external\debug_assert\debug_assert.hpp(245) : error C2220: warning treated as error - no 'object' file generated
\cppast\external\type_safe\external\debug_assert\debug_assert.hpp(245) : warning C4702: unreachable code
It's not really related to cppast, but flag /WX affected cppast compilation.
Same problem here. CMAKE_BUILD_TYPE Debug seems to work for me but the others fail.
Had the same problem recently, it's a speculation, but I think it is due to a lack of
-DDEBUG_ASSERT_DISABLE in release builds. Hope that's useful.
Same problem
Fixed with /WX- options
