Dmitry-Me
5cba4ac602
Omit unneeded deep copy
2015-12-23 10:32:59 +03:00
Dmitry-Me
155ccecf2f
Drop useless braces
2015-12-22 10:31:49 +03:00
Alexander Mai
28a625abd8
#7218 Improve performance in TokenList::validateAst(): Keep a list of 'verified' tokens during recursion check.
2015-12-19 20:36:30 +01:00
PKEuS
a6b719eb10
Refactorization: Fixed true positive when self-checking cppcheck
2015-12-18 18:13:13 +01:00
Dmitry-Me
06ff877415
Typo in variable name
2015-12-18 15:46:12 +03:00
Dmitry-Me
166e2a2cb8
Extract duplicate code
2015-12-18 10:24:02 +03:00
orbitcowboy
4a3c61f031
Merge pull request #731 from Dmitry-Me/dontProceedToOuterScope
...
Don't proceed to outer scope once there's a match in this scope
2015-12-17 16:04:59 +01:00
PKEuS
8f22e4924c
Updated AStyle to version 2.05.1
...
Tweaked runastyle.bat a little bit.
2015-12-17 15:53:13 +01:00
Dmitry-Me
ecc2e00a38
Don't proceed to outer scope once there's a match in this scope
2015-12-17 17:31:22 +03:00
orbitcowboy
bc6ae499dc
Merge pull request #730 from Dmitry-Me/loopVariableNotUsed
...
Loop variable wasn't really used
2015-12-17 15:09:41 +01:00
Dmitry-Me
6f996142dc
Loop variable wasn't really used
2015-12-17 12:54:05 +03:00
Daniel Marjamäki
febe1c9c14
Merge pull request #729 from Dmitry-Me/removeRedundantCheck
...
Remove redundant check
2015-12-16 15:03:07 +01:00
Daniel Marjamäki
bebf8ccdd5
Revert da15efb3
and 6304a4dd
to fix FPs. See #7148 , #7179 , etc
2015-12-16 14:51:50 +01:00
Dmitry-Me
0d2edc532c
Remove redundant check
2015-12-16 16:36:06 +03:00
orbitcowboy
66897a95f4
Merge pull request #727 from Dmitry-Me/fixC4706
...
Fix C4706 assignment within conditional
2015-12-15 10:58:14 +01:00
Dmitry-Me
4a8a5d4460
Fix C4706 assignment within conditional
2015-12-15 11:34:04 +03:00
Dmitry-Me
bd4b47123a
Better variable name
2015-12-15 11:30:20 +03:00
PKEuS
18693a7fce
Refactorized token.cpp:
...
- Removed redundant overload of Token::insertToken()
- Fixed leak in Token::deleteThis()
- Moved condition out of loop in Token::tokAt()
2015-12-14 22:04:51 +01:00
Daniel Marjamäki
8f27cec991
Revert "minor tweak of comment"
...
This reverts commit b1d1869f22
.
2015-12-14 20:29:29 +01:00
Daniel Marjamäki
9acda09fa2
refactoring. combine 2 if to 1
2015-12-14 20:05:17 +01:00
Daniel Marjamäki
b1d1869f22
minor tweak of comment
2015-12-14 20:03:40 +01:00
Daniel Marjamäki
2532f94bef
Merge pull request #719 from 3adev/fix-multiple-config-dumps
...
Fix multiple config dumps
2015-12-14 20:03:09 +01:00
Albert ARIBAUD (3ADEV)
e7fdb1c825
Fix multiple config dumps
...
With multiple configurations, option --dump only dumps
the last configuration.
Fix it to dump every configuration.
Also update all Python addons so that they can handle
multiple-configuration dumps.
Additionally run autopep8 on addons/*.py.
The results of 'make test' before and after applying
this commit are identical.
2015-12-14 18:20:35 +01:00
Dmitry-Me
182877df88
Variable name consistent with other code
2015-12-14 17:35:32 +03:00
Daniel Marjamäki
0baad496f2
Fixed #6383 (FP shiftNegative - value converted to unsigned in function argument)
2015-12-14 10:55:23 +01:00
Daniel Marjamäki
0cc003830a
Revert "Fix Compiler warnings."
...
This reverts commit cbb7c8b854
.
2015-12-13 19:58:27 +01:00
Albert ARIBAUD (3ADEV)
58031147b2
Optimize tokenizing
...
Reorganize cppcheck.cpp to separate actual checking from
tokenizing and XML dumping. This implies splitting checkFile()
in three parts, checkRawTokens, checkNormalTokens() and
checkSimplifiedTokens().
2015-12-13 09:29:47 +01:00
Alexander Mai
96531d6ffe
TokenList::createAst() doesn't validate itself anymore. Remove some duplicated code and fix glitch in TestGarbage::garbageCode162
2015-12-12 20:01:03 +01:00
Daniel Marjamäki
9cb8e9a07e
Revert "Fixed #3923 (valueFlowForward: assignment in if should not cause bailout for code in else)"
...
This reverts commit 04f9b71281
.
2015-12-12 16:50:02 +01:00
Alexander Mai
5b2dacb4b4
Correct travis and compiler warnings and comments
2015-12-12 16:08:52 +01:00
Daniel Marjamäki
04f9b71281
Fixed #3923 (valueFlowForward: assignment in if should not cause bailout for code in else)
2015-12-12 15:50:33 +01:00
Alexander Mai
9a847d7b14
#7208 Cppcheck hangs with 100% CPU load in CheckOther::checkNegativeBitwiseShift (invalidcode). TokenList::validateAst() is running consistency checks on AST
2015-12-12 15:39:38 +01:00
PKEuS
51bb76c5b5
Optimization: Skip over expression in brackets in Tokenizer::isFunctionParameterPassedByValue()
2015-12-10 15:53:14 +01:00
PKEuS
37572dc109
Small refactorizations:
...
- Improved formatting of unhandled-char-constant message (Side-effect: fixes #7206 )
- Replace nr="-1" by nr="any" in windows.cfg
2015-12-10 15:47:46 +01:00
Daniel Marjamäki
61da95010c
Removed unused CppCheck::replaceAll()
2015-12-10 13:32:36 +01:00
Daniel Marjamäki
1f16e72b19
Removed --debug-fp. The reduce tool should be used instead.
2015-12-10 10:44:36 +01:00
Akhilesh Nema
932f6ea81b
Cppcheck hangs with 100% CPU load in TemplateSimplifier::checkComplicatedSyntaxErrorsInTemplates (invalidcode)
2015-12-09 14:00:40 +01:00
Dmitry-Me
28bf944d81
Remove redundant checks
2015-12-09 11:10:56 +03:00
orbitcowboy
eead6862cc
Merge pull request #718 from Dmitry-Me/cacheAndReuse3
...
Cache and reuse value
2015-12-08 15:07:59 +01:00
Daniel Marjamäki
e88a1b0915
astyle formatting
2015-12-08 14:23:26 +01:00
Dmitry-Me
f96484b609
Cache and reuse value
2015-12-08 10:36:03 +03:00
Albert ARIBAUD (3ADEV)
b8dd71c577
Factorize toxml() into a single member function
...
lib/symboldatabase.cpp and lib/tokenize.cpp both
define a static toxml() function. Make it a single
static ErrorLogger::toxml() member function.
2015-12-07 18:21:01 +01:00
Akhilesh Nema
ca3c19c63d
GUI: Fixed compiler warnings
2015-12-07 11:24:54 +01:00
PKEuS
57e9954390
Merge pull request #715 from Dmitry-Me/eliminateRepeatedLookup3
...
Remove repeated lookup
2015-12-07 10:47:37 +01:00
amai2012
7129b1c5b3
Merge pull request #716 from Dmitry-Me/betterVariableName7
...
Better variable name
2015-12-07 10:35:34 +01:00
Dmitry-Me
67f0301f0b
Better variable name
2015-12-07 12:21:17 +03:00
Dmitry-Me
f00a73f1a1
Remove repeated lookup
2015-12-07 11:57:04 +03:00
Alexander Mai
26b699fd30
Fix compiler warnings about incomplete handling of library error codes
2015-12-06 12:52:49 +01:00
Alexander Mai
9d8dffbd79
#6269 false positives in case of overloaded standard library functions. Detect memset() with proper argument cound, using new function numberOfArguments()
2015-12-06 12:50:05 +01:00
PKEuS
eb27d3b877
Refactorization: Moved condition out of loop and ran AStyle
2015-12-06 10:40:22 +01:00