static int unusedVariable; int main(void){ }
./cppcheck --enable=all test.c
Checking test.c ... nofile:0:0: information: Active checkers: 107/802 (use --checkers-report=<filename> to see details) [checkersReport]
I would expect unusedVariable to be reported but nothing shows up. If I move the unusedVariable inside main(), then it is reported.
unusedVariable
main()
(I think I posted to wrong channel. )
Covered by https://trac.cppcheck.net/ticket/10690
Log in to post a comment.
./cppcheck --enable=all test.cI would expect
unusedVariableto be reported but nothing shows up.If I move the
unusedVariableinsidemain(), then it is reported.(I think I posted to wrong channel. )
Last edit: Dzid 2024-06-13
Covered by https://trac.cppcheck.net/ticket/10690