fixed unit testing

This commit is contained in:
Daniel Marjamäki 2009-12-23 19:59:46 +01:00
parent ea51c3e098
commit 9b05850e97
2 changed files with 2 additions and 2 deletions

View File

@ -1252,7 +1252,7 @@ private:
return vartok->next();
}
if (Token::Match(tok.previous(), "[;{}] %var% ("))
if (Token::Match(&tok, "%var% ("))
{
// parse usage..
std::list<const Token *> var;

View File

@ -1216,7 +1216,7 @@ private:
" FILE *f;\n"
" fflush(f);\n"
"}\n");
ASSERT_EQUALS("error", errout.str());
ASSERT_EQUALS("[test.cpp:4]: (error) Uninitialized variable: f\n", errout.str());
// arrays..
checkUninitVar("void f()\n"