In InsertValueInst's copy ctor, actually copy the operands.
authorDan Gohman <gohman@apple.com>
Tue, 17 Jun 2008 23:25:49 +0000 (23:25 +0000)
committerDan Gohman <gohman@apple.com>
Tue, 17 Jun 2008 23:25:49 +0000 (23:25 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52434 91177308-0d34-0410-b5e6-96231b3b80d8

lib/VMCore/Instructions.cpp

index 604f9f94a1c178b601357a31671646d72918687c..5b8e2917152d79486b231283dc1226532a92a732 100644 (file)
@@ -1385,6 +1385,8 @@ InsertValueInst::InsertValueInst(const InsertValueInst &IVI)
   : Instruction(IVI.getType(), InsertValue,
                 OperandTraits<InsertValueInst>::op_begin(this), 2),
     Indices(IVI.Indices) {
+  Op<0>() = IVI.getOperand(0);
+  Op<1>() = IVI.getOperand(1);
 }
 
 InsertValueInst::InsertValueInst(Value *Agg,