summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore/IntrinsicInst.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/VMCore/IntrinsicInst.cpp')
-rw-r--r--llvm/lib/VMCore/IntrinsicInst.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/llvm/lib/VMCore/IntrinsicInst.cpp b/llvm/lib/VMCore/IntrinsicInst.cpp
index daa768c0cfe..cb9252efdf5 100644
--- a/llvm/lib/VMCore/IntrinsicInst.cpp
+++ b/llvm/lib/VMCore/IntrinsicInst.cpp
@@ -54,6 +54,10 @@ Value *DbgInfoIntrinsic::StripCast(Value *C) {
/// DbgValueInst - This represents the llvm.dbg.value instruction.
///
-Value *DbgValueInst::getValue() const {
+const Value *DbgValueInst::getValue() const {
+ return cast<MDNode>(getOperand(1))->getOperand(0);
+}
+
+Value *DbgValueInst::getValue() {
return cast<MDNode>(getOperand(1))->getOperand(0);
}
OpenPOWER on IntegriCloud