aboutsummaryrefslogtreecommitdiffstats
path: root/lib/VMCore/IntrinsicInst.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/VMCore/IntrinsicInst.cpp')
-rw-r--r--lib/VMCore/IntrinsicInst.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/VMCore/IntrinsicInst.cpp b/lib/VMCore/IntrinsicInst.cpp
index 8bdb944..2c2c5a9 100644
--- a/lib/VMCore/IntrinsicInst.cpp
+++ b/lib/VMCore/IntrinsicInst.cpp
@@ -45,13 +45,13 @@ static Value *CastOperand(Value *C) {
Value *DbgInfoIntrinsic::StripCast(Value *C) {
if (Value *CO = CastOperand(C)) {
- return StripCast(CO);
+ C = StripCast(CO);
} else if (GlobalVariable *GV = dyn_cast<GlobalVariable>(C)) {
if (GV->hasInitializer())
if (Value *CO = CastOperand(GV->getInitializer()))
- return StripCast(CO);
+ C = StripCast(CO);
}
- return C;
+ return dyn_cast<GlobalVariable>(C);
}
//===----------------------------------------------------------------------===//