From e4d5c441e04bdc00ccf1804744af670655123b07 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Tue, 15 Mar 2005 04:54:21 +0000 Subject: 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 --- lib/Transforms/Utils/CodeExtractor.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'lib/Transforms/Utils/CodeExtractor.cpp') 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 -- cgit v1.2.3-18-g5258