diff options
author | Chris Lattner <sabre@nondot.org> | 2005-03-15 04:54:21 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2005-03-15 04:54:21 +0000 |
commit | e4d5c441e04bdc00ccf1804744af670655123b07 (patch) | |
tree | be1bff1314e39651d7120d2d887b79b10dc2f24d /lib/Transforms/Utils/CodeExtractor.cpp | |
parent | 89cc2656ba070434dceeabe95cba0a95b988325b (diff) |
This mega patch converts us from using Function::a{iterator|begin|end} to
using Function::arg_{iterator|begin|end}. Likewise Module::g* -> Module::global_*.
This patch is contributed by Gabor Greif, thanks!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20597 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils/CodeExtractor.cpp')
-rw-r--r-- | lib/Transforms/Utils/CodeExtractor.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Transforms/Utils/CodeExtractor.cpp b/lib/Transforms/Utils/CodeExtractor.cpp index 5a04001005..cf9cafb04a 100644 --- a/lib/Transforms/Utils/CodeExtractor.cpp +++ b/lib/Transforms/Utils/CodeExtractor.cpp @@ -295,7 +295,7 @@ Function *CodeExtractor::constructFunction(const Values &inputs, newFunction->getBasicBlockList().push_back(newRootNode); // Create an iterator to name all of the arguments we inserted. - Function::aiterator AI = newFunction->abegin(); + Function::arg_iterator AI = newFunction->arg_begin(); // Rewrite all users of the inputs in the extracted region to use the // arguments (or appropriate addressing into struct) instead. @@ -322,7 +322,7 @@ Function *CodeExtractor::constructFunction(const Values &inputs, // Set names for input and output arguments. if (!AggregateArgs) { - AI = newFunction->abegin(); + AI = newFunction->arg_begin(); for (unsigned i = 0, e = inputs.size(); i != e; ++i, ++AI) AI->setName(inputs[i]->getName()); for (unsigned i = 0, e = outputs.size(); i != e; ++i, ++AI) @@ -406,7 +406,7 @@ emitCallAndSwitchStatement(Function *newFunction, BasicBlock *codeReplacer, NumExitBlocks > 1 ? "targetBlock" : ""); codeReplacer->getInstList().push_back(call); - Function::aiterator OutputArgBegin = newFunction->abegin(); + Function::arg_iterator OutputArgBegin = newFunction->arg_begin(); unsigned FirstOut = inputs.size(); if (!AggregateArgs) std::advance(OutputArgBegin, inputs.size()); @@ -483,7 +483,7 @@ emitCallAndSwitchStatement(Function *newFunction, BasicBlock *codeReplacer, OldTarget); // Restore values just before we exit - Function::aiterator OAI = OutputArgBegin; + Function::arg_iterator OAI = OutputArgBegin; for (unsigned out = 0, e = outputs.size(); out != e; ++out) { // For an invoke, the normal destination is the only one that is // dominated by the result of the invocation |