aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-08-04 02:27:17 +0000
committerChris Lattner <sabre@nondot.org>2004-08-04 02:27:17 +0000
commit07d7c9d9c508ec67a86ed572819d8cf9e3bdc422 (patch)
tree1eb880263499996fd944ddc07c799d12f29b1546 /lib
parent17c2b922d78c9151854630529ee5ed15427cb24a (diff)
Add a cast
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@15457 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/VMCore/Globals.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/VMCore/Globals.cpp b/lib/VMCore/Globals.cpp
index ea87701011..2369d1c8ea 100644
--- a/lib/VMCore/Globals.cpp
+++ b/lib/VMCore/Globals.cpp
@@ -120,7 +120,7 @@ void GlobalVariable::replaceUsesOfWithOnConstant(Value *From, Value *To,
"Attempt to replace GVar initializer with non-constant");
// Okay, preconditions out of the way, replace the constant initializer.
- this->setOperand(0,To);
+ this->setOperand(0, cast<Constant>(To));
}
// vim: sw=2 ai