Yep, this is the same problem. Thanks guys. Hoping to see it get fixed, I may look into it myself :-)
While using the latest cppcheck I found an issue with the following error error: Syntax Error: AST broken, 'if' doesn't have two operands. [internalAstError] This error happens when I do the following HANDLE fileHandle = INVALID_HANDLE_VALUE; auto func = call_to_fun([&fileHandle]() { if (fileHandle != INVALID_HANDLE_VALUE) closeHandle(fileHandle) }); I was looking in the cppcheck code in tokenlist.cpp in order to see what's wrong. It looks like this shouldn't be a problem as it is lembda. In fact,...
While using the latest cppcheck I found an issue with the following error error: Syntax Error: AST broken, 'if' doesn't have two operands. [internalAstError] This error happens when I do the following HANDLE fileHandle = INVALID_HANDLE_VALUE; auto func = call_to_fun([&fileHandle]() { if (fileHandle != INVALID_HANDLE_VALUE) // closeHandle(fileHandle) }); I was looking in the cppcheck code in tokenlist.cpp in order to see what's wrong. It looks like this shouldn't be a problem as it is lembda. In fact,...
My problem was fixed, because the enums were already declared in another library that I was using. enum class attr { text, file ... }; These were already used, so when I changed the names in enum, my problem was resolved.
I updated to 1.87 from 1.86. Now I am having this issue. I tried to use the fix --language=c++, but doesn't work