[LLParser] Fix uninitialized flag variable warnings. NFCI.

Fixes a large number of warnings in the scan-build report on llvm builds.

llvm-svn: 361772
This commit is contained in:
Simon Pilgrim 2019-05-27 16:33:15 +00:00
parent 20c3c4fe5a
commit d99f9373d3
1 changed files with 2 additions and 2 deletions

View File

@ -8484,7 +8484,7 @@ bool LLParser::ParseGVFlags(GlobalValueSummary::GVFlags &GVFlags) {
return true;
do {
unsigned Flag;
unsigned Flag = 0;
switch (Lex.getKind()) {
case lltok::kw_linkage:
Lex.Lex();
@ -8536,7 +8536,7 @@ bool LLParser::ParseGVarFlags(GlobalVarSummary::GVarFlags &GVarFlags) {
assert(Lex.getKind() == lltok::kw_varFlags);
Lex.Lex();
unsigned Flag;
unsigned Flag = 0;
if (ParseToken(lltok::colon, "expected ':' here") ||
ParseToken(lltok::lparen, "expected '(' here") ||
ParseToken(lltok::kw_readonly, "expected 'readonly' here") ||