Begin the painful process of tearing apart the rat'ss nest that is Constants.cpp...
[oota-llvm.git] / lib / CodeGen / UnreachableBlockElim.cpp
index c3b213cebe9543a95020d13b26a95c215e91661d..003470d954aeb5bb799cc876fff5d54854b408e0 100644 (file)
@@ -68,7 +68,7 @@ bool UnreachableBlockElim::runOnFunction(Function &F) {
       BasicBlock *BB = I;
       DeadBlocks.push_back(BB);
       while (PHINode *PN = dyn_cast<PHINode>(BB->begin())) {
-        PN->replaceAllUsesWith(Constant::getNullValue(PN->getType()));
+        PN->replaceAllUsesWith(Context->getNullValue(PN->getType()));
         BB->getInstList().pop_front();
       }
       for (succ_iterator SI = succ_begin(BB), E = succ_end(BB); SI != E; ++SI)