From 090db0267d94b01a06543dd5021c4a6acfc09f44 Mon Sep 17 00:00:00 2001 From: "Duncan P. N. Exon Smith" Date: Tue, 20 Oct 2015 01:12:49 +0000 Subject: [PATCH] AsmParser: Remove implicit ilist iterator conversions, NFC git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@250791 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/AsmParser/LLParser.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/lib/AsmParser/LLParser.cpp b/lib/AsmParser/LLParser.cpp index 02b4b75b040..d5e5848422b 100644 --- a/lib/AsmParser/LLParser.cpp +++ b/lib/AsmParser/LLParser.cpp @@ -185,7 +185,7 @@ bool LLParser::ValidateEndOfModule() { // Look for intrinsic functions and CallInst that need to be upgraded for (Module::iterator FI = M->begin(), FE = M->end(); FI != FE; ) - UpgradeCallsToIntrinsic(FI++); // must be post-increment, as we remove + UpgradeCallsToIntrinsic(&*FI++); // must be post-increment, as we remove UpgradeDebugInfo(*M); @@ -2263,10 +2263,9 @@ LLParser::PerFunctionState::PerFunctionState(LLParser &p, Function &f, : P(p), F(f), FunctionNumber(functionNumber) { // Insert unnamed arguments into the NumberedVals list. - for (Function::arg_iterator AI = F.arg_begin(), E = F.arg_end(); - AI != E; ++AI) - if (!AI->hasName()) - NumberedVals.push_back(AI); + for (Argument &A : F.args()) + if (!A.hasName()) + NumberedVals.push_back(&A); } LLParser::PerFunctionState::~PerFunctionState() { -- 2.34.1