From bc744272f8f761284514efe44a59fa23d6455bb7 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Thu, 19 May 2016 20:44:22 +0000 Subject: [PATCH] Fix -Wunused-variable in non-Asserts build llvm-svn: 270118 --- llvm/lib/Target/Hexagon/MCTargetDesc/HexagonInstPrinter.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonInstPrinter.cpp b/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonInstPrinter.cpp index 572d845efba9..42fcc5a6aa89 100644 --- a/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonInstPrinter.cpp +++ b/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonInstPrinter.cpp @@ -202,10 +202,9 @@ void HexagonInstPrinter::printPredicateOperand(MCInst const *MI, unsigned OpNo, void HexagonInstPrinter::printSymbol(MCInst const *MI, unsigned OpNo, raw_ostream &O, bool hi) const { - MCOperand const &MO = MI->getOperand(OpNo); + assert(MI->getOperand(OpNo).isImm() && "Unknown symbol operand"); O << '#' << (hi ? "HI" : "LO") << '('; - assert(MO.isImm() && "Unknown symbol operand"); O << '#'; printOperand(MI, OpNo, O); O << ')';