llvm.org GIT mirror llvm / 803f5fc
Do not allow a user to set the operand for a constant. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58335 91177308-0d34-0410-b5e6-96231b3b80d8 Tanya Lattner 11 years ago
1 changed file(s) with 3 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
9494 }
9595 void setOperand(unsigned i, Value *Val) {
9696 assert(i < NumOperands && "setOperand() out of range!");
97 assert((!isa((const Value*)this) ||
98 isa((const Value*)this)) &&
99 "Cannot mutate a constant with setOperand!");
97100 OperandList[i] = Val;
98101 }
99102 unsigned getNumOperands() const { return NumOperands; }