From: Sanjoy Das Date: Sun, 30 Oct 2016 23:52:53 +0000 (+0000) Subject: [SCEV] Use auto for consistency with an upcoming change; NFC X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=641d7278d9450d56da9ce1a4ff563f384e3b820a;p=llvm [SCEV] Use auto for consistency with an upcoming change; NFC git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@285528 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Analysis/ScalarEvolution.cpp b/lib/Analysis/ScalarEvolution.cpp index f03051ddb4a..fd8cec54826 100644 --- a/lib/Analysis/ScalarEvolution.cpp +++ b/lib/Analysis/ScalarEvolution.cpp @@ -471,16 +471,16 @@ static int CompareValueComplexity(const LoopInfo *const LI, Value *LV, return (int)LID - (int)RID; // Sort arguments by their position. - if (const Argument *LA = dyn_cast(LV)) { - const Argument *RA = cast(RV); + if (const auto *LA = dyn_cast(LV)) { + const auto *RA = cast(RV); unsigned LArgNo = LA->getArgNo(), RArgNo = RA->getArgNo(); return (int)LArgNo - (int)RArgNo; } // For instructions, compare their loop depth, and their operand count. This // is pretty loose. - if (const Instruction *LInst = dyn_cast(LV)) { - const Instruction *RInst = cast(RV); + if (const auto *LInst = dyn_cast(LV)) { + const auto *RInst = cast(RV); // Compare loop depths. const BasicBlock *LParent = LInst->getParent(),