[llvm] r245520 - MIR Parser: parseIRValue should take in a constant pointer. NFC.
Alex Lorenz via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 19 16:27:07 PDT 2015
Author: arphaman
Date: Wed Aug 19 18:27:07 2015
New Revision: 245520
URL: http://llvm.org/viewvc/llvm-project?rev=245520&view=rev
Log:
MIR Parser: parseIRValue should take in a constant pointer. NFC.
Modified:
llvm/trunk/lib/CodeGen/MIRParser/MIParser.cpp
Modified: llvm/trunk/lib/CodeGen/MIRParser/MIParser.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/MIRParser/MIParser.cpp?rev=245520&r1=245519&r2=245520&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/MIRParser/MIParser.cpp (original)
+++ llvm/trunk/lib/CodeGen/MIRParser/MIParser.cpp Wed Aug 19 18:27:07 2015
@@ -150,7 +150,7 @@ public:
bool parseOffset(int64_t &Offset);
bool parseAlignment(unsigned &Alignment);
bool parseOperandsOffset(MachineOperand &Op);
- bool parseIRValue(Value *&V);
+ bool parseIRValue(const Value *&V);
bool parseMemoryOperandFlag(unsigned &Flags);
bool parseMemoryPseudoSourceValue(const PseudoSourceValue *&PSV);
bool parseMachinePointerInfo(MachinePointerInfo &Dest);
@@ -1523,7 +1523,7 @@ bool MIParser::parseOperandsOffset(Machi
return false;
}
-bool MIParser::parseIRValue(Value *&V) {
+bool MIParser::parseIRValue(const Value *&V) {
switch (Token.kind()) {
case MIToken::NamedIRValue: {
V = MF.getFunction()->getValueSymbolTable().lookup(Token.stringValue());
@@ -1631,7 +1631,7 @@ bool MIParser::parseMachinePointerInfo(M
}
if (Token.isNot(MIToken::NamedIRValue))
return error("expected an IR value reference");
- Value *V = nullptr;
+ const Value *V = nullptr;
if (parseIRValue(V))
return true;
if (!V->getType()->isPointerTy())
More information about the llvm-commits
mailing list