summaryrefslogtreecommitdiff
path: root/lib/Bytecode
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2005-01-31 01:11:13 +0000
committerChris Lattner <sabre@nondot.org>2005-01-31 01:11:13 +0000
commit613233230b78acae4c96d91b1efdd08f2e966380 (patch)
tree4ec57a7d656c02cc6a99df1d5c84865a1811899d /lib/Bytecode
parentf9aace20fbd9b821f6297d19768ab568bd0e6db8 (diff)
downloadllvm-613233230b78acae4c96d91b1efdd08f2e966380.tar.gz
llvm-613233230b78acae4c96d91b1efdd08f2e966380.tar.bz2
llvm-613233230b78acae4c96d91b1efdd08f2e966380.tar.xz
Fix the regressions my User changes introduced. Apparently some parts of
LLVM make the very reasonable assumption that constant expressions will have at least one operand! :) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19943 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bytecode')
-rw-r--r--lib/Bytecode/Reader/Reader.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/Bytecode/Reader/Reader.cpp b/lib/Bytecode/Reader/Reader.cpp
index a36aa99509..cf68d678e2 100644
--- a/lib/Bytecode/Reader/Reader.cpp
+++ b/lib/Bytecode/Reader/Reader.cpp
@@ -38,8 +38,11 @@ namespace {
ConstantPlaceHolder(); // DO NOT IMPLEMENT
void operator=(const ConstantPlaceHolder &); // DO NOT IMPLEMENT
public:
+ Use Op;
ConstantPlaceHolder(const Type *Ty)
- : ConstantExpr(Ty, Instruction::UserOp1, 0, 0) {}
+ : ConstantExpr(Ty, Instruction::UserOp1, &Op, 1),
+ Op(UndefValue::get(Type::IntTy), this) {
+ }
};
}