Fixed #7476 (SymbolDatabase: Wrong data with single ; in line)

This commit is contained in:
Robert Reif 2016-05-12 11:35:02 +02:00 committed by Daniel Marjamäki
parent 99d0dbf39c
commit 97bbb7da0d
1 changed files with 3 additions and 5 deletions

View File

@ -497,12 +497,10 @@ SymbolDatabase::SymbolDatabase(const Tokenizer *tokenizer, const Settings *setti
tok = tok->tokAt(2);
}
scope->addFunction(function);
}
// skip over unknown tokens
while (tok && tok->str() != ";")
tok = tok->next();
// 'const' or unknown macro (#5197)
else if (Token::Match(end, ") %any% ;")) {
tok = end->tokAt(2);
scope->addFunction(function);
}