Commit Graph

677 Commits

Author SHA1 Message Date
Daniel Marjamäki 2e3a7db4eb Fixed #4115 (Incorrect uninitialized variable error message with realloc macro) 2012-09-22 18:41:33 +02:00
Edoardo Prezioso 406483b618 Fixed valgrind error in #3953 , but there's still the bad enum problem. 2012-09-20 21:07:37 +02:00
Daniel Marjamäki c3cb6202ed Fixed #4172 (TemplateSimplifier: Handle 'A<&f> x' template instantiation) 2012-09-19 16:10:13 +02:00
Ettl Martin 3f89e38275 fixed #4195 segmentation fault of cppcheck (invalid code); Added a testcase 2012-09-19 10:37:30 +02:00
Daniel Marjamäki 1f7d9ca22c Fixed #4211 (Tokenizer::simplifyVarDecl: Improved handling of >> in templates) 2012-09-17 19:45:42 +02:00
XhmikosR 3c14e4b52a test: tabs to spaces, remove trailing spaces and extra empty lines at the end of files 2012-09-17 13:51:40 +02:00
Daniel Marjamäki f1ebd99dc2 Fixed #3507 (false positive: comma-separated statements before return in methods) 2012-09-15 11:55:08 +02:00
Daniel Marjamäki 9f2e1ab98d Fixed #4048 (Tokenizer::simplifyVarDecl: Improve handling of 'a::b const * p = 0;') 2012-09-14 16:46:45 +02:00
Daniel Marjamäki 19fdbf0fd0 Fixed #4185 (Incorrect 'Found duplicate if expressions' for strings with high bit set) 2012-09-13 16:44:10 +02:00
PKEuS ce9f6bdb56 Fixed segfault #4182 2012-09-10 17:33:52 +02:00
PKEuS d44f10fc01 Fixed createLinks2() on this code: nvwa<(x > y)> 2012-09-09 15:31:23 +02:00
Daniel Marjamäki 107b3b4401 Fixed #4171 (don't choke when parentheses are missing from macros) 2012-09-09 09:48:07 +02:00
Daniel Marjamäki a39b58046f Tokenizer: Improved simplification of 'a?(1):b' 2012-09-08 10:45:00 +02:00
Daniel Marjamäki 2722f53edd Fixed #4142 (false positive (error) Uninitialized variable: b) 2012-09-08 10:15:37 +02:00
Daniel Marjamäki c31ce68520 TestTokenizer: Added TODO assertion 2012-09-08 09:01:02 +02:00
Daniel Marjamäki 2ce5cb3075 Tokenizer: Simplified parentheses better in such pattern: 'git merge --squash 4142 operator git merge --squash 4142 (%var%|)) ( %num%|%bool% ) %op%|;|,|)' 2012-09-08 07:01:35 +02:00
PKEuS 489df29346 Moved Tokenizer::typeConstToConstType() to Tokenizer::simplifyConst() 2012-09-07 11:41:41 +02:00
Daniel Marjamäki 1c7027140a Tokenizer: Improved simplifyRedundantParanthesis 2012-09-06 16:16:29 +02:00
Daniel Marjamäki 3032ded9aa replaced tabs with spaces 2012-09-05 19:46:44 +02:00
anuraggarg011 913670d254 Fixed #3304 (simple cases) 2012-09-04 13:41:14 +02:00
Edoardo Prezioso 6fd60eebb0 Tokenizer: added a workaround for #3690 (Support MSVC's 'for each'). 2012-09-03 20:23:53 +02:00
anuraggarg011 bf11248a09 Fixed #1620 (tokenizer: simplify well known math functions) 2012-09-03 18:51:15 +02:00
PKEuS ea85dd305a Fixed #4086: Set varId in initialization list. 2012-08-28 12:44:40 +02:00
PKEuS 662b0d2dbe Simplify 0[foo] to *(foo) (fixes #4083) 2012-08-26 10:03:05 +02:00
PKEuS 9fa7e15fb4 Fixed setVarId for nested templates (#3976, #3769) and support C++11 right angle brackets in TemplateSimplifier::templateParameters() 2012-08-26 09:49:38 +02:00
Daniel Marjamäki f127728582 Enable --std=c11 and --std=c++11 by default 2012-08-25 21:57:45 +02:00
Daniel Marjamäki 985ac662ee Fixed #4035 (False positive: Memory leak: pTempFile) 2012-08-25 12:00:25 +02:00
Daniel Marjamäki 5051837c1a Reverted last commit. I pushed it by mistake. 2012-08-25 11:00:51 +02:00
Daniel Marjamäki 5e1ccfaf90 Fixed #4035 (False positive: Memory leak: pTempFile) 2012-08-25 10:55:20 +02:00
PKEuS 43e01a2b1a Ran AStyle, removed redundant tokAt(0) 2012-08-22 16:51:44 +02:00
SAndeep 0600b0be8f sprintf changes 2012-08-22 16:46:14 +02:00
Daniel Marjamäki 9ffc7f4c2d Fixed #3964 (False positive: Expressions in array declarations are not simplified 'char mac[17+1];') 2012-08-20 18:10:32 +02:00
PKEuS 2ac2674f67 Fixed #4000, added support for function prototypes to TemplateSimplifier::templateParameters() 2012-08-12 05:19:56 -07:00
Daniel Marjamäki 435340b463 Fixed #3814 (false positive: missing constructor) 2012-07-29 16:01:05 +02:00
PKEuS 1ec3c9f634 Fixed hang in libreoffice code (simplification of K&R style function declaration tried to simplify a function with parameters without name whose implementation contained "; {".
Test cases of this simplification only need basic simplifications done in Tokenizer::tokenize
2012-07-29 06:11:48 -07:00
PKEuS e9182f1fcc Implemented support for 'using namespace std;': Add std:: prefix to names that are known to be in std namespace. Simplify namespace (std::)tr1:: if C++11 flag is set. 2012-07-15 02:05:19 -07:00
Daniel Marjamäki bf98e952c1 Fixed #3927 (false positive: (error) Uninitialized variable: new) 2012-07-08 13:59:00 +02:00
Thomas Sondergaard f72ddbb2e9 Fixed #3912 (Analysis failed) 2012-07-03 06:34:14 +02:00
Daniel Marjamäki bb9f114d84 Fixed #3924 (False positive: Uninitialized variable (const pointer)) 2012-06-30 12:12:36 +02:00
Daniel Marjamäki 8af044255d Tokenizer: Added new function isFunctionParameterPassedByValue that check if a parameter is passed by value 2012-06-24 13:40:09 +02:00
Daniel Marjamäki 974225626d Fixed #3901 (false positive: (error) Uninitialized variable: temp) 2012-06-19 20:07:39 +02:00
Daniel Marjamäki 5174f7ff5e Fixed #3723 (Preprocessor evaluation order) 2012-06-14 21:47:03 +02:00
Daniel Marjamäki 4b6e1c6946 Fixed #3855 (false positive: (error) Instance of 'locale' object destroyed immediately) 2012-06-13 19:21:20 +02:00
August Sodora 90f92250dd Fixed #3618 (segmentation fault of cppcheck) 2012-06-12 21:07:17 +02:00
Daniel Marjamäki 54a66391d8 Fixed #3750 (false positive: C-style pointer casting) 2012-06-12 18:45:31 +02:00
August Sodora e146591b5d Fixed #3544 (segmentation fault of cppcheck) 2012-06-02 16:15:12 +02:00
Daniel Marjamäki 5b0551054a varid: better templates handling 2012-05-22 18:58:13 +02:00
PKEuS 0157f937bf Fixed #3760: Added explicit to C++ keyword list in setVarId
Made some constant arrays static
2012-05-16 01:59:52 -07:00
Daniel Marjamäki 4ae8e4f382 Tokenizer::setVarId: Minor fix of sizeof handling 2012-05-15 18:40:24 +02:00
Daniel Marjamäki a0e5fad6a9 Fixed #3776 (Tokenizer::setVarId: No varid set when unknown macro is used before variable declaration) 2012-05-15 07:17:31 +02:00