Commit Graph

32 Commits

Author SHA1 Message Date
Kimmo Varis a71ce607a4 Tests: Re-enable style param for testdivision.
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)
2011-08-10 23:46:26 +03:00
Kimmo Varis cfcfa3f000 Use "enabled" list for the style checking.
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.
2011-08-07 10:28:52 +03:00
Simon Martin 539c2e5acb Fixed #2932 (segmentation fault of cppcheck ( i / i )) 2011-07-24 09:06:38 +02:00
Pete Johns 098f0bf3e6 Fixed #2526 (Make TODO_ASSERT_EQUALS take three arguments (value, to_be, as_is)?...
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.
2011-01-30 23:20:11 +11:00
Reijo Tomperi 226b605774 Change year 2010 -> 2011 in license texts. 2011-01-09 21:33:36 +02:00
Robert Reif f12c0c7ada Tokenizer: add assert(_settings) to Tokenizer to insure the tokenizer always has settings. Ticket: #2219 2010-12-01 18:00:55 +01:00
Daniel Marjamäki 6edb2e77b4 Refactoring: Removed Severity::possibleStyle 2010-05-16 14:43:42 +02:00
Daniel Marjamäki c0e9a546f7 Refactoring: Refactoring the Settings class 2010-04-17 09:23:54 +02:00
Reijo Tomperi 35d2a27b9c Update copyright year in all source files 2010-04-13 22:23:17 +03:00
Daniel Marjamäki e9b4ea44a2 Refactoring: Disable inconclusive checks. They can still be activated for debugging/testing purposes 2010-04-10 14:05:33 +02:00
Robert Reif ef57d01f7a Fixed #1492 (false negatives: array index out of bounds) 2010-03-31 17:14:49 +02:00
Reijo Tomperi b52fa9451f Fix #1385 (False positive: unsigned division)
http://sourceforge.net/apps/trac/cppcheck/ticket/1385
This also fixes a bug in setVarId(). "unsigned int a" didn't get varid,
untill later when unsigned was simplified away.
2010-02-12 22:24:06 +02:00
Daniel Marjamäki 09859c1019 refactoring the folder structure 2009-10-25 12:49:06 +01:00
Reijo Tomperi 1401e3f668 Fix #810 (false positive: Division with signed and unsigned operators)
http://sourceforge.net/apps/trac/cppcheck/ticket/810
2009-10-11 17:52:35 +03:00
Reijo Tomperi fdde2182b9 Fix GPL comments in all files. ">." was missing from the end. 2009-09-27 18:08:31 +03:00
Slava Semushin 9d65a1ebe8 test/testdivision.cpp: fixed syntax errors in TestDivision::division8
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.
2009-09-22 23:53:26 +07:00
Daniel Marjamäki 36c7108a28 Fixed #669 (possible style without --all + false positives) 2009-09-15 20:46:47 +02:00
Daniel Marjamäki 7d35447d80 refactoring: renamed the severity "all" to "possible error" 2009-07-13 10:16:31 +02:00
Reijo Tomperi 8b0e481d46 Refactoring: Rename member functions to follow naming guidelines. 2009-07-05 23:16:43 +03:00
Slava Semushin 52a8368b02 Strip redundant std::string usage from tests.
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.
2009-06-05 07:43:55 +07:00
Slava Semushin e5c0383594 Strip redundant std::string usage from tests.
Done by command:
git grep -l ASSERT_EQUALS | xargs sed -i 's|ASSERT_EQUALS(std::string(\(".\+"\)),|ASSERT_EQUALS(\1,|'

Should be no functional change.
2009-06-01 02:50:25 +07:00
Reijo Tomperi 58eda6e978 Fix ticket #325 (Replace developer names in source files with AUTHORS file)
http://apps.sourceforge.net/trac/cppcheck/ticket/325
2009-05-30 08:48:12 +03:00
Reijo Tomperi dd8b738f7f Initial fix for ticket #283 (segmentation fault when checking xterm sources)
http://apps.sourceforge.net/trac/cppcheck/ticket/283
It should print out error message now instead of crashing. Cleanup is needed.
2009-05-07 23:17:29 +03:00
Daniel Marjamäki 9f1c3cc535 refactoring the rest of the classes 2009-03-20 18:16:21 +01:00
Reijo Tomperi fc8f47145a Copyrights updated 2009-03-01 19:52:33 +00:00
Reijo Tomperi b211b8cbe8 Fix ticket #84 (unit testing: use "protected" instead of preprocessor) 2009-02-07 20:06:00 +00:00
Reijo Tomperi a06861948b Fixed: Ticket #78 Change (always) into (error) in error messages 2009-02-05 21:06:32 +00:00
Daniel Marjamäki 3457b38d7a errmsg: write severity in the message 2009-01-31 08:33:31 +00:00
Reijo Tomperi 176dd41306 Fixed Ticket #40, Check copyright texts in files, now that we have new developers. 2009-01-21 20:04:20 +00:00
Daniel Marjamäki 15a32103e2 testdivision: The 'unsigned division' is a style check 2009-01-12 17:20:32 +00:00
Daniel Marjamäki 980b10bfc9 errmsg: Added 'unsigned division' 2009-01-12 17:12:14 +00:00
Reijo Tomperi e435a1f1d6 Refactoring: Added src/ and test/ folders. Moved source files to those folders, updated makefile and codeblocks project file. 2009-01-06 14:18:36 +00:00