aboutsummaryrefslogtreecommitdiff
path: root/lib/MC/MCValue.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/MC/MCValue.cpp')
-rw-r--r--lib/MC/MCValue.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/MC/MCValue.cpp b/lib/MC/MCValue.cpp
index 043a49d80c..c6ea16ce7b 100644
--- a/lib/MC/MCValue.cpp
+++ b/lib/MC/MCValue.cpp
@@ -8,6 +8,7 @@
//===----------------------------------------------------------------------===//
#include "llvm/MC/MCValue.h"
+#include "llvm/MC/MCExpr.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/raw_ostream.h"
@@ -19,10 +20,12 @@ void MCValue::print(raw_ostream &OS, const MCAsmInfo *MAI) const {
return;
}
- OS << *getSymA();
+ getSymA()->print(OS);
- if (getSymB())
- OS << " - " << *getSymB();
+ if (getSymB()) {
+ OS << " - ";
+ getSymB()->print(OS);
+ }
if (getConstant())
OS << " + " << getConstant();