[llvm] 9a738c4 - [NFCI] Fix set-but-unused warning in RISCVAsmParser.cpp
Dávid Bolvanský via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 24 00:33:55 PDT 2022
Author: Dávid Bolvanský
Date: 2022-03-24T08:33:40+01:00
New Revision: 9a738c477e0b1ae6d5b7328b65e7ed99a5ab4f24
URL: https://github.com/llvm/llvm-project/commit/9a738c477e0b1ae6d5b7328b65e7ed99a5ab4f24
DIFF: https://github.com/llvm/llvm-project/commit/9a738c477e0b1ae6d5b7328b65e7ed99a5ab4f24.diff
LOG: [NFCI] Fix set-but-unused warning in RISCVAsmParser.cpp
Added:
Modified:
llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp b/llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
index c34757750bf33..ab0a0fcd9c446 100644
--- a/llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
+++ b/llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
@@ -1995,7 +1995,6 @@ bool RISCVAsmParser::ParseInstruction(ParseInstructionInfo &Info,
return true;
// Parse until end of statement, consuming commas between operands
- unsigned OperandIdx = 1;
while (getLexer().is(AsmToken::Comma)) {
// Consume comma token
getLexer().Lex();
@@ -2003,8 +2002,6 @@ bool RISCVAsmParser::ParseInstruction(ParseInstructionInfo &Info,
// Parse next operand
if (parseOperand(Operands, Name))
return true;
-
- ++OperandIdx;
}
if (getLexer().isNot(AsmToken::EndOfStatement)) {
More information about the llvm-commits
mailing list