diff options
author | Matthijs Kooijman <matthijs@stdin.nl> | 2008-05-30 12:35:46 +0000 |
---|---|---|
committer | Matthijs Kooijman <matthijs@stdin.nl> | 2008-05-30 12:35:46 +0000 |
commit | 57da7d230895e3263f60d8b2b02d51a9054c4fcb (patch) | |
tree | 691c619133a5e25b361d9e5e0010de06687728ff /llvm/lib | |
parent | f7fe41656c317fff867335186ae848b4d45c5a75 (diff) | |
download | bcm5719-llvm-57da7d230895e3263f60d8b2b02d51a9054c4fcb.tar.gz bcm5719-llvm-57da7d230895e3263f60d8b2b02d51a9054c4fcb.zip |
Use eraseFromParent() instead of doing that manually in two places.
llvm-svn: 51770
Diffstat (limited to 'llvm/lib')
-rw-r--r-- | llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp b/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp index 2dab6952247..1ca5a3982ae 100644 --- a/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp +++ b/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp @@ -626,7 +626,7 @@ void DAE::RemoveDeadArgumentsFromFunction(Function *F) { // Finally, remove the old call from the program, reducing the use-count of // F. - Call->getParent()->getInstList().erase(Call); + Call->eraseFromParent(); } // Since we have now created the new function, splice the body of the old @@ -665,7 +665,7 @@ void DAE::RemoveDeadArgumentsFromFunction(Function *F) { } // Now that the old function is dead, delete it. - F->getParent()->getFunctionList().erase(F); + F->eraseFromParent(); } bool DAE::runOnModule(Module &M) { |