Commit Graph

7232 Commits

Author SHA1 Message Date
Daniel Marjamäki 6f2bbc0ba6 1.52: Updated Makefile 2011-12-10 13:00:45 +01:00
Daniel Marjamäki f58d023753 1.52: Updated Changelog 2011-12-10 12:56:36 +01:00
Daniel Marjamäki 93b447f7f6 1.52: Updated version 2011-12-10 12:55:40 +01:00
PKEuS 9fc7453917 Memory leaks: Code cleanups 2011-12-10 11:55:14 +01:00
Daniel Marjamäki 8624c0b9fd Merge pull request #67 from makulik/master
Fixed ticket #3389 '-U option doesn't supress include file handling for #include statements inside #ifdef code paths'
2011-12-10 02:44:01 -08:00
Daniel Marjamäki c2e86b867c Fixed #3386 (Syntax Error: 'int a[]={b<c?1:2,3};') 2011-12-10 11:34:27 +01:00
Edoardo Prezioso 51c1e2303f CheckBufferOverrun::checkInsecureCmdLineArgs(): Remove recently unused variable 'pattern'. 2011-12-09 23:24:08 +01:00
PKEuS 91a0a071d0 Take symbol database into use or improve its usage in some checks. 2011-12-09 23:28:10 +02:00
makulik 0a777dcb52 Fixed ticket #3389 '-U option doesn't supress include file handling for #include statements inside #ifdef code paths'
Signed-off-by: makulik <g-makulik@t-online.de>
2011-12-09 21:57:06 +01:00
PKEuS 9b685ba3c3 Code cleanup 2011-12-09 21:00:57 +01:00
Edoardo Prezioso 7d12951da0 1)Fixed ticket #3184 (Improve Tokenizer: improve simplifyMulAnd to simplify weirder code);
2)Fix a test case inside TestSimplifyTokens::flowControl.
2011-12-09 20:47:51 +01:00
PKEuS f46cf5fd65 Exception safety: refactorings, use the symbol database 2011-12-09 19:53:00 +01:00
Daniel Marjamäki 8ca8887849 C++ Builder : Fixed compiler error 2011-12-08 22:24:09 +01:00
Daniel Marjamäki b383bae4ab C++ Builder: Fixed compiler errors 2011-12-08 22:17:50 +01:00
Daniel Marjamäki 6029e23189 Preprocessor: Use const_iterator instead of iterator where possible 2011-12-08 22:14:11 +01:00
Daniel Marjamäki 60d828e778 C++ Builder: Fixed compiler error 2011-12-08 22:09:03 +01:00
PKEuS 167a7e3e51 Various code cleanups 2011-12-08 21:28:34 +01:00
Daniel Marjamäki e2dd085b60 Fixed #3394 (False positive: possible null pointer dereference) 2011-12-08 19:30:14 +01:00
PKEuS 1bef8d1247 Tokenizer: Code cleanups 2011-12-08 17:42:26 +01:00
Edoardo Prezioso 149ff355e2 Add more kind of code to process for 'removeExceptionSpecifications' (unions, anonymous unions and structs). 2011-12-08 02:50:05 +01:00
Edoardo Prezioso 4de5d87078 1)Remove newly copy of 'eraseTokens' and replace every occurrence with 'deleteNext' with right parameter.
2)General improvements to code.
2011-12-08 01:44:18 +01:00
Edoardo Prezioso 76972e8dd3 Extend 'Token::deleteNext' by introducing a new parameter which determines how many tokens should be deleted. It's still not used, though. 2011-12-07 23:36:11 +01:00
Daniel Marjamäki 5cc5330d95 extracttests.py: reverted last change. see comments on github. 2011-12-07 21:49:34 +01:00
PKEuS 1c1c31bea0 Tokenizer: Refactorings and improvements. Better handling of [] 2011-12-07 21:15:00 +01:00
PKEuS 97eecb78a7 Fixed #3381 (false positive: (style) Statements following return, break, continue, goto or throw will never be executed) 2011-12-07 18:20:52 +01:00
Daniel Marjamäki ab348387b5 extracttests.py: python 3 compatibility updates 2011-12-07 17:05:24 +01:00
Edoardo Prezioso 612b3c59ca 1)Implement another declaration of 'Token::eraseTokens' with parameters: the starting token and the number of times needed to call 'deleteNext'.
2)Use the overloaded 'eraseTokens' where needed instead of using consecutively 'deleteNext'.
3)Tokenizer: general optimizations about the deletion of some tokens.
4)Run astyle.
2011-12-07 02:29:03 +01:00
Edoardo Prezioso b9224439c1 Add 'exit' and 'abort' to the flow control list in order to simplify code after them. 2011-12-06 22:56:12 +01:00
Edoardo Prezioso eb5fe250ab Partial fix ticket #3385 ('throw' isn't removed if the argument of the function is type 'struct|class'). 2011-12-06 21:02:26 +01:00
Ettl Martin 4884a1dfe0 sanity check for ticket #3387 ( buffer access out of bounds) 2011-12-06 20:53:56 +01:00
Edoardo Prezioso 0504952950 Remove some redundant parenthesis - part 9 2011-12-06 16:53:57 +01:00
Edoardo Prezioso 1b4b8fbefe Tokenizer: use more 'deleteNext' instead of 'eraseTokens' where possible. 2011-12-05 18:52:34 +01:00
Edoardo Prezioso c8bbb77776 CheckMemoryLeakInFunction::simplifycode : use properly 'deleteNext' instead of 'deleteThis' or 'eraseTokens' and remove redundant conversion to 'std::string'. 2011-12-05 15:50:11 +01:00
Edoardo Prezioso 186ab3645e Oops. I should eventually keep ';', not 'typedef'. 2011-12-05 00:26:08 +01:00
Edoardo Prezioso 65213772df Tokenizer: use 'deleteNext()' or, even better, 'eraseTokens' instead of 'deleteThis()' where possible. 2011-12-05 00:08:50 +01:00
Daniel Marjamäki e9546c5042 extracttests.py: create output folders if they dont exist 2011-12-04 21:46:56 +01:00
PKEuS 501d7ccb2d Optimize checkother.cpp by taking symbolDatabase into use. 2011-12-04 20:49:01 +02:00
Edoardo Prezioso 9cadd7c17a Remove some redundant semicolons - part 8 2011-12-04 19:11:51 +01:00
Edoardo Prezioso 4946b036ad Remove some redundant semicolons - part 7 2011-12-04 18:08:35 +01:00
Edoardo Prezioso 52a174fa9d Remove some redundant semicolons - part 6 2011-12-04 17:30:25 +01:00
Edoardo Prezioso b45d63a10a Remove some redundant semicolons - part 5 2011-12-04 17:15:53 +01:00
Edoardo Prezioso 2fc067e6ab Tokenizer::simplifyConst : handle also '%type% const' when the 'type' token is the first one in the list. 2011-12-04 16:59:19 +01:00
Edoardo Prezioso a363749a17 1) Remove some redundant semicolons - part 4 ('typedef' != _tokens.str());
2) Tokenizer: Use Token::eraseTokens instead of using the same instructions as the ones inside such function.
2011-12-04 15:40:05 +01:00
Daniel Marjamäki eeb6dc48a5 Fixed #3359 (False positive: array[idx++] += val triggers unexpected 'Array index out of bounds' error) 2011-12-04 12:22:21 +01:00
Daniel Marjamäki 49784a44e1 Tokenizer: improved handling of inner templates. Partial fix for #3226 2011-12-04 11:38:41 +01:00
Edoardo Prezioso f47ac539d6 Tokenizer::simplifyFlowControl: 1) remove consecutive 'break' or 'continue', since they don't influence the CheckOther results; 2) improve the code speed where possible;
Tokenizer::eraseDeadCode: Ditto.
2011-12-03 17:15:19 +01:00
Thomas Jarosch fcb6759f43 The usual astyle run 2011-12-03 17:01:56 +01:00
Daniel Marjamäki 50dfdf7c2e Fixed #3350 (Analysis failed) 2011-12-03 15:15:15 +01:00
Daniel Marjamäki c90558f730 Fixed #3358 (False null pointer dereference positive with ternary ?: operator) 2011-12-03 13:10:07 +01:00
Daniel Marjamäki b7988a3dab Fixed #3336 (False positive: Member function is not used (used by template function)) 2011-12-03 12:19:26 +01:00