Fixed #4278 (syntax error).
This commit is contained in:
parent
c7961b147d
commit
1e4b080737
|
@ -2390,8 +2390,9 @@ bool Tokenizer::simplifyLabelsCaseDefault()
|
|||
if (Token::Match(tok->next(),"[:{};]"))
|
||||
break;
|
||||
}
|
||||
if (tok->str() != "case" && tok->next()->str() == ":" && tok->strAt(2) != ";") {
|
||||
if (tok->str() != "case" && tok->next()->str() == ":") {
|
||||
tok = tok->next();
|
||||
if (tok->next()->str() != ";")
|
||||
tok->insertToken(";");
|
||||
} else {
|
||||
syntaxError(tok);
|
||||
|
|
Loading…
Reference in New Issue