astyle formatting

[ci skip]
This commit is contained in:
Daniel Marjamäki 2016-01-08 15:24:05 +01:00
parent e92bbf6481
commit 0b9d8ae0f1
2 changed files with 5 additions and 5 deletions

View File

@ -2309,8 +2309,8 @@ void Tokenizer::simplifyLabelsCaseDefault()
break; break;
if (tok->str() != "case" && tok->next() && tok->next()->str() == ":") { if (tok->str() != "case" && tok->next() && tok->next()->str() == ":") {
tok = tok->next(); tok = tok->next();
if (!tok->next()) if (!tok->next())
syntaxError(tok); // #7270 invalid code syntaxError(tok); // #7270 invalid code
if (tok->next()->str() != ";" && tok->next()->str() != "case") if (tok->next()->str() != ";" && tok->next()->str() != "case")
tok->insertToken(";"); tok->insertToken(";");
else else

View File

@ -219,7 +219,7 @@ private:
TEST_CASE(garbageCode168); // #7246 TEST_CASE(garbageCode168); // #7246
TEST_CASE(garbageCode169); // #6731 TEST_CASE(garbageCode169); // #6731
TEST_CASE(garbageCode170); TEST_CASE(garbageCode170);
TEST_CASE(garbageCode171); TEST_CASE(garbageCode171);
TEST_CASE(garbageValueFlow); TEST_CASE(garbageValueFlow);
TEST_CASE(garbageSymbolDatabase); TEST_CASE(garbageSymbolDatabase);
TEST_CASE(garbageAST); TEST_CASE(garbageAST);
@ -1442,8 +1442,8 @@ private:
// 7255 // 7255
checkCode("d i(){{f*s=typeid(()0,)}}", false); checkCode("d i(){{f*s=typeid(()0,)}}", false);
} }
void garbageCode171() { void garbageCode171() {
// 7270 // 7270
ASSERT_THROW(checkCode("(){case()?():}:", false), InternalError); ASSERT_THROW(checkCode("(){case()?():}:", false), InternalError);
} }