Merge pull request #312 from matthiaskrgr/travis
travis: compile one pair of jobs with -DCHECK_INTERNAL and run --enable=internal,...
This commit is contained in:
commit
d3d3803ae4
|
@ -13,7 +13,7 @@ env:
|
|||
# special CXXFLAGS for maximum speed, overrides global CXXFLAGS, CHECK_KERNEL is the var that controls if we download and check the kernel in that travis job
|
||||
- MAKEFLAGS="HAVE_RULES=yes" SRCDIR=build VERIFY=1
|
||||
- SRCDIR=build VERIFY=1
|
||||
-
|
||||
- CXXFLAGS="${CXXFLAGS} -DCHECK_INTERNAL"
|
||||
- CXXFLAGS="-O3 -march=native -mtune=native" SRCDIR=build CHECK_KERNEL=yes
|
||||
|
||||
matrix:
|
||||
|
@ -46,7 +46,7 @@ script:
|
|||
- cd ../
|
||||
# use same hack as for kernel to work around cppchecks broken exit status with -j 2 ; create file, tee everything to the file and stdout, grep for errors in the file
|
||||
- touch /tmp/cppcheck.cppcheck
|
||||
- ./cppcheck --error-exitcode=1 -Ilib --enable=style --suppressions-list=.travis_suppressions . -j 2 |& tee /tmp/cppcheck.cppcheck
|
||||
- ./cppcheck --error-exitcode=1 -Ilib --enable=style,performance,portability,warning,internal --suppressions-list=.travis_suppressions . -j 2 |& tee /tmp/cppcheck.cppcheck
|
||||
- sh -c "! grep '^\[' /tmp/cppcheck.cppcheck"
|
||||
- cd ./gui
|
||||
# clean rebuild
|
||||
|
|
|
@ -2,6 +2,7 @@ uselessAssignmentPtrArg:build/checkstl.cpp
|
|||
assertWithSideEffect:build/checkuninitvar.cpp
|
||||
duplicateBranch:build/checkunusedvar.cpp
|
||||
unusedPrivateFunction:test/testcmdlineparser.cpp
|
||||
redundantNextPrevious:test/testtoken.cpp
|
||||
*:gui/test*
|
||||
*:test/test.cxx
|
||||
|
||||
|
|
|
@ -951,7 +951,7 @@ static void valueFlowForLoopSimplify(Token * const bodyStart, const unsigned int
|
|||
setTokenValue(tok2, value1);
|
||||
}
|
||||
|
||||
else if (Token::Match(tok2, ") {") && Token::findmatch(tok2->link(), "%varid%", tok2, varid)) {
|
||||
else if (Token::simpleMatch(tok2, ") {") && Token::findmatch(tok2->link(), "%varid%", tok2, varid)) {
|
||||
if (Token::findmatch(tok2, "continue|break|return", tok2->linkAt(1), varid)) {
|
||||
if (settings->debugwarnings)
|
||||
bailout(tokenlist, errorLogger, tok2, "For loop variable bailout on conditional continue|break|return");
|
||||
|
@ -960,7 +960,7 @@ static void valueFlowForLoopSimplify(Token * const bodyStart, const unsigned int
|
|||
if (settings->debugwarnings)
|
||||
bailout(tokenlist, errorLogger, tok2, "For loop variable skipping conditional scope");
|
||||
tok2 = tok2->next()->link();
|
||||
if (Token::Match(tok2, "} else {")) {
|
||||
if (Token::simpleMatch(tok2, "} else {")) {
|
||||
if (Token::findmatch(tok2, "continue|break|return", tok2->linkAt(2), varid)) {
|
||||
if (settings->debugwarnings)
|
||||
bailout(tokenlist, errorLogger, tok2, "For loop variable bailout on conditional continue|break|return");
|
||||
|
|
Loading…
Reference in New Issue