summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-mc
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/tools/llvm-mc')
-rw-r--r--llvm/tools/llvm-mc/AsmExpr.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/tools/llvm-mc/AsmExpr.cpp b/llvm/tools/llvm-mc/AsmExpr.cpp
index fbb0c53b1cf..226dd130b1e 100644
--- a/llvm/tools/llvm-mc/AsmExpr.cpp
+++ b/llvm/tools/llvm-mc/AsmExpr.cpp
@@ -26,16 +26,16 @@ bool AsmExpr::EvaluateAsAbsolute(MCContext &Ctx, int64_t &Res) const {
return true;
}
-static bool EvaluateSymbolicAdd(const MCValue &LHS, MCSymbol *RHS_A,
- MCSymbol *RHS_B, int64_t RHS_Cst,
+static bool EvaluateSymbolicAdd(const MCValue &LHS, const MCSymbol *RHS_A,
+ const MCSymbol *RHS_B, int64_t RHS_Cst,
MCValue &Res) {
// We can't add or subtract two symbols.
if ((LHS.getSymA() && RHS_A) ||
(LHS.getSymB() && RHS_B))
return false;
- MCSymbol *A = LHS.getSymA() ? LHS.getSymA() : RHS_A;
- MCSymbol *B = LHS.getSymB() ? LHS.getSymB() : RHS_B;
+ const MCSymbol *A = LHS.getSymA() ? LHS.getSymA() : RHS_A;
+ const MCSymbol *B = LHS.getSymB() ? LHS.getSymB() : RHS_B;
if (B) {
// If we have a negated symbol, then we must have also have a non-negated
// symbol in order to encode the expression. We can do this check later to
OpenPOWER on IntegriCloud