My earlier commit (cfcfa3f0) removed the use of style parameter.
This commit adds it back.
Ticket: #2987 (GCC: warning: unused parameter ‘style’ in test/testdivision.cpp:39:10)
Settings-class currently enables style checking via dedicated
boolean attribute. All other CLI's enable-options are handled
through the enable-list. This commit moves style-check enabling
to use the enable-list.
Main advantage is the consistency how options are handled/stored
in the Settings class. Which also unifies using them for the other
code. You need to enable certain type of checks? Use the
addEnabled()-method. You want to check if certain type of checks
are enabled? Use the isEnabled()-method.
Removed replaced EXPECTED with...
WANTED (to-be): The future expected value.
CURRENT (as-is): Documenting how cppcheck behaves now.
This removes the need for an ASSERT_EQUALS but enforces the check for every TODO_ASSERT_EQUALS.
Before testrunner complains:
### Unlogged error at Tokenizer::syntaxError: Invalid number of character ({)
### Unlogged error at Tokenizer::syntaxError: Invalid number of character ({)
### Unlogged error at Tokenizer::syntaxError: Invalid number of character ({)
Broken since 36c7108a28 commit where
test case was added.
Second round: handle empty strings.
Done by command:
git grep -l ASSERT_EQUALS | xargs sed -i 's|ASSERT_EQUALS(std::string(\(".*"\)),|ASSERT_EQUALS(\1,|'
Should be no functional change.