aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Transforms/Utils/InstructionNamer.cpp
diff options
context:
space:
mode:
authorOwen Anderson <resistor@mac.com>2009-08-13 21:58:54 +0000
committerOwen Anderson <resistor@mac.com>2009-08-13 21:58:54 +0000
commit55f1c09e31cfc6744fb682e17a2a1a00d914694c (patch)
treee753e20c7186dc8138bef58089274bb5162a7cef /llvm/lib/Transforms/Utils/InstructionNamer.cpp
parent41a750271b72216801366693bd0f41672892c487 (diff)
downloadllvm-55f1c09e31cfc6744fb682e17a2a1a00d914694c.zip
llvm-55f1c09e31cfc6744fb682e17a2a1a00d914694c.tar.gz
llvm-55f1c09e31cfc6744fb682e17a2a1a00d914694c.tar.bz2
Push LLVMContexts through the IntegerType APIs.
llvm-svn: 78948
Diffstat (limited to 'llvm/lib/Transforms/Utils/InstructionNamer.cpp')
-rw-r--r--llvm/lib/Transforms/Utils/InstructionNamer.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/Utils/InstructionNamer.cpp b/llvm/lib/Transforms/Utils/InstructionNamer.cpp
index 4f8a160..1fa51a3 100644
--- a/llvm/lib/Transforms/Utils/InstructionNamer.cpp
+++ b/llvm/lib/Transforms/Utils/InstructionNamer.cpp
@@ -32,7 +32,7 @@ namespace {
bool runOnFunction(Function &F) {
for (Function::arg_iterator AI = F.arg_begin(), AE = F.arg_end();
AI != AE; ++AI)
- if (!AI->hasName() && AI->getType() != Type::VoidTy)
+ if (!AI->hasName() && AI->getType() != Type::getVoidTy(F.getContext()))
AI->setName("tmp");
for (Function::iterator BB = F.begin(), E = F.end(); BB != E; ++BB) {
@@ -40,7 +40,7 @@ namespace {
BB->setName("BB");
for (BasicBlock::iterator I = BB->begin(), E = BB->end(); I != E; ++I)
- if (!I->hasName() && I->getType() != Type::VoidTy)
+ if (!I->hasName() && I->getType() != Type::getVoidTy(F.getContext()))
I->setName("tmp");
}
return true;