forked from OSchip/llvm-project
[AsmPrinter] DebugLocEntry::dump() - Use const-ref iterator in for-range loop. NFCI.
Avoid unnecessary copies, reported by MSVC static analyzer.
This commit is contained in:
parent
e4b2f66d7f
commit
9e70d4e5f2
|
@ -158,7 +158,7 @@ public:
|
||||||
friend bool operator<(const DbgValueLoc &, const DbgValueLoc &);
|
friend bool operator<(const DbgValueLoc &, const DbgValueLoc &);
|
||||||
#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
|
#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
|
||||||
LLVM_DUMP_METHOD void dump() const {
|
LLVM_DUMP_METHOD void dump() const {
|
||||||
for (DbgValueLocEntry DV : ValueLocEntries)
|
for (const DbgValueLocEntry &DV : ValueLocEntries)
|
||||||
DV.dump();
|
DV.dump();
|
||||||
if (Expression)
|
if (Expression)
|
||||||
Expression->dump();
|
Expression->dump();
|
||||||
|
|
Loading…
Reference in New Issue