Added break statements to various default: cases

No behavioral changes, just stylistic.

Change-Id: I95a54bb2ee5610272ecea4886163ba79ae2544a2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/447837
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
This commit is contained in:
Ethan Nicholas 2021-09-10 16:49:42 -04:00 committed by SkCQ
parent 144926d968
commit b13f36944c
6 changed files with 11 additions and 1 deletions

View File

@ -233,6 +233,7 @@ std::unique_ptr<Program> DSLParser::program() {
default:
this->declaration();
done = fEncounteredFatalError;
break;
}
}
End();
@ -1184,6 +1185,7 @@ skstd::optional<DSLBlock> DSLParser::block() {
return skstd::nullopt;
}
statements.push_back(statement->release());
break;
}
}
}

View File

@ -199,6 +199,7 @@ void Dehydrator::write(const Symbol& s) {
this->writeCommand(Rehydrator::kSystemType_Command);
this->writeId(&t);
this->write(t.name());
break;
}
break;
}

View File

@ -147,6 +147,7 @@ std::unique_ptr<ASTFile> Parser::compilationUnit() {
if (decl) {
getNode(result).addChild(decl);
}
break;
}
}
}

View File

@ -787,6 +787,7 @@ void GLSLCodeGenerator::writeVariableReference(const VariableReference& ref) {
break;
default:
this->write(ref.variable()->name());
break;
}
}

View File

@ -305,6 +305,7 @@ void SPIRVCodeGenerator::writeString(skstd::string_view s, OutputStream& out) {
break;
default:
this->writeWord(0, out);
break;
}
}
@ -649,6 +650,7 @@ SpvId SPIRVCodeGenerator::getType(const Type& rawType, const MemoryLayout& layou
} else {
SkDEBUGFAILF("invalid type: %s", type->description().c_str());
}
break;
}
fTypeMap[key] = result;
return result;
@ -1875,6 +1877,7 @@ std::vector<SpvId> SPIRVCodeGenerator::getAccessChain(const Expression& expr, Ou
SpvId id = this->getLValue(expr, out)->getPointer();
SkASSERT(id != (SpvId) -1);
chain.push_back(id);
break;
}
}
return chain;

View File

@ -45,7 +45,7 @@ void RegexParser::term() {
case '(': this->group(); break;
case '[': this->set(); break;
case '.': this->dot(); break;
default: this->literal();
default: this->literal(); break;
}
}
@ -71,6 +71,7 @@ void RegexParser::sequence() {
RegexNode right = this->pop();
RegexNode left = this->pop();
fStack.emplace(RegexNode::kConcat_Kind, std::move(left), std::move(right));
break;
}
}
}
@ -152,6 +153,7 @@ void RegexParser::set() {
exit(1);
default:
this->setItem();
break;
}
}
}