[llvm] r372872 - Fix cppcheck variable shadow warning. NFCI.
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 25 06:45:36 PDT 2019
Author: rksimon
Date: Wed Sep 25 06:45:36 2019
New Revision: 372872
URL: http://llvm.org/viewvc/llvm-project?rev=372872&view=rev
Log:
Fix cppcheck variable shadow warning. NFCI.
Modified:
llvm/trunk/lib/IR/ConstantsContext.h
Modified: llvm/trunk/lib/IR/ConstantsContext.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/ConstantsContext.h?rev=372872&r1=372871&r2=372872&view=diff
==============================================================================
--- llvm/trunk/lib/IR/ConstantsContext.h (original)
+++ llvm/trunk/lib/IR/ConstantsContext.h Wed Sep 25 06:45:36 2019
@@ -678,9 +678,9 @@ public:
/// Hash once, and reuse it for the lookup and the insertion if needed.
LookupKeyHashed Lookup(MapInfo::getHashValue(Key), Key);
- auto I = Map.find_as(Lookup);
- if (I != Map.end())
- return *I;
+ auto ItMap = Map.find_as(Lookup);
+ if (ItMap != Map.end())
+ return *ItMap;
// Update to the new value. Optimize for the case when we have a single
// operand that we're changing, but handle bulk updates efficiently.
More information about the llvm-commits
mailing list