Commit Graph

209 Commits

Author SHA1 Message Date
Daniel Marjamäki 6f8e42a5af changed the astyle formatting flags 2011-10-13 20:53:06 +02:00
Daniel Marjamäki 787bc4c384 Fixed #3016 (Preprocessor has incorrect precedence(?) for &&) 2011-08-28 18:30:58 +02:00
Daniel Marjamäki e82df7292f Fixed #2919 (Wrong file name reported with #error in header) 2011-08-03 07:28:37 +02:00
Reijo Tomperi ee7b8d53c6 Fix: #2942 (segmentation fault of cppcheck ( #elif (){ ))
http://sourceforge.net/apps/trac/cppcheck/ticket/2942
2011-08-02 22:06:27 +03:00
Simon Martin fc0f75fe6a Preprocessor: Fix #if0 #elif todo test case. Ticket: #2619 2011-07-24 08:54:24 +02:00
Daniel Marjamäki 7e7f6eecf5 Fixed #2794 (Improper hanling of preprocessor directives #if defined) 2011-07-20 23:50:57 +02:00
Daniel Marjamäki b66e6e73db Fixed #2917 (Problem with || in #if) 2011-07-18 21:44:23 +02:00
Daniel Marjamäki c55b0ff651 Fixed #2871 (Define in source not set when -D is used) 2011-07-16 16:59:06 +02:00
Daniel Marjamäki 07a1222ac6 Preprocessor: fix handling of (1&&2) condition 2011-07-16 09:24:27 +02:00
Daniel Marjamäki be9e66efff Fixed #2782 (Segfault with #asm) 2011-05-11 19:27:19 +02:00
Daniel Marjamäki 6fc59b0257 Fixed #2740 (inline cmd // cppcheck-suppress does not work anymore for 1.48) 2011-04-22 20:25:17 +02:00
Daniel Marjamaki fbc8223a6b Preprocessor: Fixed expandMacros problem. Ticket: #2707 2011-04-07 16:53:42 +02:00
Daniel Marjamäki a2d2d93958 astyle formatting 2011-03-01 17:58:15 +01:00
Greg Hewgill baf50c6db1 add TODO for #elif inside #if 0 processing, also for #if 1 2011-03-01 20:24:03 +13:00
Greg Hewgill 2efb2efaca refactor #if 0 handling to leave preprocessor statements alone 2011-03-01 20:04:11 +13:00
Greg Hewgill a331516735 handle #if (0) after removing parentheses 2011-03-01 19:50:17 +13:00
Greg Hewgill 31c56d7353 handle embedded whitespace in #if 0 processing 2011-03-01 19:32:47 +13:00
Greg Hewgill 87fd55b155 test case for #if 0 exclusion 2011-03-01 19:30:42 +13:00
Daniel Marjamäki ab2bf0ee0c Fixed #2575 (false positive: Preprocessor does not ignore #include within #if 0 block) 2011-02-26 10:04:38 -08:00
Daniel Marjamäki 32a49235e3 Fixed #2578 (Preprocessor does not correctly handle #define A 0 / #if A) 2011-02-23 13:08:24 -08:00
Daniel Marjamäki 9983aa5721 Fixed #2605 (cppcheck hangs with 100% cpu load ( #define = )) 2011-02-22 19:55:02 +01:00
Daniel Marjamäki c3fba356c0 Fixed #2563 (#if equality testing does not ignore parentheses) 2011-02-20 20:57:28 +01:00
Daniel Marjamäki f6e6fa685e Preprocessor: Added TODO test case for #2563 2011-02-20 20:11:51 +01:00
Daniel Marjamäki 8c5ec0df7d Merge branch 'preprocessor' of https://github.com/ghewgill/cppcheck into ghewgill-preprocessor 2011-02-13 18:13:35 +01:00
Greg Hewgill a4fd5e873e change failing tests into TODO_ASSERT_EQUALS 2011-02-13 20:45:04 +13:00
Greg Hewgill f2f2d1f885 Fixed #2571 (Preprocessor: better handling for #undef) 2011-02-11 18:51:22 +01:00
Greg Hewgill 751f8d46e5 Fixed #2570 (Preprocessor: #define parsing when there is no whitespace between a macro symbol and its double-quoted string expansion) 2011-02-11 18:01:27 +01:00
Erik Lax b3e8ef9d48 Fixed #2559 (Refactoring Preprocessor::read) 2011-02-11 06:30:42 +01:00
Greg Hewgill c0d3e002a9 preprocessor check for #define A 0 2011-02-08 21:02:15 +13:00
Daniel Marjamäki 7c9e52546d Fixed #2552 (preprocessor check XX is already guaranteed to be defined -- too eager?) 2011-02-07 20:26:29 +01:00
Daniel Marjamäki 757c840633 astyle formatting 2011-01-31 17:26:07 +01:00
Raphael Geissert 66253af1e5 Handle "#endif !defined" conditionals 2011-01-30 17:33:44 -06:00
Raphael Geissert b944168bdc Check for cpp conditionals where a define is already guaranteed 2011-01-30 12:47:17 -06: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
Raphael Geissert 49848fd752 Remove duplicated defines
After simplifying define(A) conditionals, the final list of
configurations could end up containing duplicate items.

Ticket #1468
2011-01-30 02:13:32 -06:00
Reijo Tomperi 226b605774 Change year 2010 -> 2011 in license texts. 2011-01-09 21:33:36 +02:00
Daniel Marjamäki 2e7e118cb8 Fixed #2392 (Preprocessor: Wrong simplification of __VA_ARGS__) 2011-01-02 11:19:37 +01:00
Daniel Marjamäki 571704f118 Added TODO testcase for ticket #2392 (Preprocessor: Wrong simplification of __VA_ARGS__) 2011-01-02 10:09:50 +01:00
Daniel Marjamäki a9aa6375b7 gcc: disabled -Wconversion again - too many warnings 2011-01-01 09:16:31 +01:00
Ettl Martin a55d7df8a3 test:testpreprocessor.cpp; fixed broken unit test due to wrong charcter encoding 2010-12-15 21:34:31 +01:00
vBm 46a11183a5 Fixed some spelling mistakes 2010-12-15 18:45:53 +01: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 86e517c5d3 Fixed #1951 (Preprocessor: Compound macro statements not handled correctly) 2010-09-24 21:38:11 +02:00
Daniel Marjamäki a6ff3681bb Fixed #1802 (Preprocessor: macros are expanded wrong) 2010-09-18 22:20:01 +02:00
Daniel Marjamäki 42d0ad8262 Fixed #2048 (Preprocessor: ifndef incorrectly simplified) 2010-09-14 17:45:37 +02:00
Daniel Marjamäki b0bb71ee20 Preprocessor: Handle C++0x rawstrings by replacing them with normal strings. Ticket: #2022 2010-09-13 19:36:40 +02:00
Robert Reif aae2986361 Fixed #2042 (#error messages should be displayed when user defines are used) 2010-09-12 21:30:47 +02:00
Daniel Marjamäki f490ebcf88 Fixed #1872 (Confused -v switch) 2010-09-03 13:30:49 +02:00
Daniel Marjamäki 427c0f4bfd Fixed #1975 (segmentation fault of cppcheck) 2010-09-02 23:01:12 +02:00
Daniel Marjamäki d45186d645 Added --debug-warnings that we can use to enable various debug warnings 2010-08-27 20:28:00 +02:00