Test without the suppressfile, you can see you have a warning about functionStatic :
cppcheck --inconclusive --enable=all --project=compile_commands.json
Checking /tmp/cppchecktest/main.cpp ...
[/tmp/cppchecktest/main.cpp:3]: (performance, inconclusive) Technically the member function 'A::foo' can be static (but you may consider moving to unnamed namespace).
Test with the suppressfile, you can see the warning disappears but you now have a wrong "Unmatched suppression"
The problem appears only with --project=compile_commands.json.
If I do a direct verification of main.cpp :
cppcheck --inconclusive --enable=all ../main.cpp
Checking ../main.cpp ...
[../main.cpp:3]: (performance, inconclusive) Technically the member function 'A::foo' can be static (but you may consider moving to unnamed namespace).
Hi,
I have a main.cpp
a CMakeLists.txt
and a suppressfile.txt :
Please, run :
Test without the suppressfile, you can see you have a warning about functionStatic :
Test with the suppressfile, you can see the warning disappears but you now have a wrong "Unmatched suppression"
The problem appears only with --project=compile_commands.json.
If I do a direct verification of main.cpp :
and with the suppressfile :
By the way, is it possible to have a trac account with the mail cppcheck[@]le-garrec(.)fr
Thanks