Skip to content

Commit

Permalink
[SystemZ] Fix compiler warnings introduced by r285574
Browse files Browse the repository at this point in the history
SystemZAsmParser::parseOperand returns a bool, not an enum.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@285800 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
uweigand committed Nov 2, 2016
1 parent d433991 commit ef86dbb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/Target/SystemZ/AsmParser/SystemZAsmParser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1113,14 +1113,14 @@ bool SystemZAsmParser::parseOperand(OperandVector &Operands,
const MCExpr *Expr;
const MCExpr *Length;
if (parseAddress(HaveReg1, Reg1, HaveReg2, Reg2, Expr, Length))
return MatchOperand_ParseFail;
return true;
// If the register combination is not valid for any instruction, reject it.
// Otherwise, fall back to reporting an unrecognized instruction.
if (HaveReg1 && Reg1.Group != RegGR && Reg1.Group != RegV
&& parseAddressRegister(Reg1))
return MatchOperand_ParseFail;
return true;
if (HaveReg2 && parseAddressRegister(Reg2))
return MatchOperand_ParseFail;
return true;

SMLoc EndLoc =
SMLoc::getFromPointer(Parser.getTok().getLoc().getPointer() - 1);
Expand Down

0 comments on commit ef86dbb

Please sign in to comment.