Fix ticket #269 (Incorrect variable id, when delete is used.)
http://apps.sourceforge.net/trac/cppcheck/ticket/269
This commit is contained in:
parent
d4a7256686
commit
7e5c32b7f4
|
@ -625,7 +625,7 @@ void Tokenizer::setVarId()
|
|||
if (Token::Match(tok, "[,;{}(] %type%"))
|
||||
tok = tok->next();
|
||||
|
||||
if (Token::Match(tok, "else|return|typedef"))
|
||||
if (Token::Match(tok, "else|return|typedef|delete"))
|
||||
continue;
|
||||
|
||||
if (Token::simpleMatch(tok, "std ::"))
|
||||
|
|
|
@ -1094,7 +1094,7 @@ private:
|
|||
"4: delete a@1 ;\n"
|
||||
"5: }\n");
|
||||
|
||||
TODO_ASSERT_EQUALS(expected, actual);
|
||||
ASSERT_EQUALS(expected, actual);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue