From 478cd98b22cd1e645cd15a6475773b8cf5a857ee Mon Sep 17 00:00:00 2001 From: Sanjoy Das Date: Fri, 14 Apr 2017 15:50:19 +0000 Subject: [PATCH] Use range for llvm-svn: 300334 --- llvm/lib/Analysis/ScalarEvolutionNormalization.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/llvm/lib/Analysis/ScalarEvolutionNormalization.cpp b/llvm/lib/Analysis/ScalarEvolutionNormalization.cpp index 21d1c1827139..d700eacc5845 100644 --- a/llvm/lib/Analysis/ScalarEvolutionNormalization.cpp +++ b/llvm/lib/Analysis/ScalarEvolutionNormalization.cpp @@ -120,9 +120,7 @@ const SCEV *PostIncTransform::TransformImpl(const SCEV *S) { SmallVector Operands; bool Changed = false; // Transform each operand. - for (SCEVNAryExpr::op_iterator I = X->op_begin(), E = X->op_end(); - I != E; ++I) { - const SCEV *O = *I; + for (auto *O : X->operands()) { const SCEV *N = TransformSubExpr(O); Changed |= N != O; Operands.push_back(N);