diff options
Diffstat (limited to 'llvm/lib/Transforms/IPO/IPConstantPropagation.cpp')
| -rw-r--r-- | llvm/lib/Transforms/IPO/IPConstantPropagation.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/llvm/lib/Transforms/IPO/IPConstantPropagation.cpp b/llvm/lib/Transforms/IPO/IPConstantPropagation.cpp index 2dc85582469..e4a9deadd97 100644 --- a/llvm/lib/Transforms/IPO/IPConstantPropagation.cpp +++ b/llvm/lib/Transforms/IPO/IPConstantPropagation.cpp @@ -241,15 +241,11 @@ bool IPCP::PropagateConstantReturn(Function &F) { for (Value::use_iterator I = Call->use_begin(), E = Call->use_end(); I != E;) { - Instruction *Ins = dyn_cast<Instruction>(*I); + Instruction *Ins = cast<Instruction>(*I); // Increment now, so we can remove the use ++I; - // Not an instruction? Ignore - if (!Ins) - continue; - // Find the index of the retval to replace with int index = -1; if (ExtractValueInst *EV = dyn_cast<ExtractValueInst>(Ins)) |

