Tokenizer:simplifyKeyword(): Improved matching when the static keyword is removed.
This commit is contained in:
parent
c1e37ff691
commit
e3009bdd0b
|
@ -9268,10 +9268,11 @@ void Tokenizer::simplifyKeyword()
|
|||
|
||||
// simplify static keyword:
|
||||
// void foo( int [ static 5 ] ); ==> void foo( int [ 5 ] );
|
||||
if (Token::Match(tok, "[ static "))
|
||||
if (Token::Match(tok, "[ static %num%")) {
|
||||
tok->deleteNext();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (_settings->standards.c >= Standards::C11) {
|
||||
for (Token *tok = list.front(); tok; tok = tok->next()) {
|
||||
|
|
Loading…
Reference in New Issue