[llvm] fe3b4f0 - [SDAG] Use reference type in loop (NFC) (#174379)
via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 5 02:42:45 PST 2026
Author: Benjamin Maxwell
Date: 2026-01-05T10:42:41Z
New Revision: fe3b4f0e0d569162aa26dd6e4cbe6d5b051e7b7b
URL: https://github.com/llvm/llvm-project/commit/fe3b4f0e0d569162aa26dd6e4cbe6d5b051e7b7b
DIFF: https://github.com/llvm/llvm-project/commit/fe3b4f0e0d569162aa26dd6e4cbe6d5b051e7b7b.diff
LOG: [SDAG] Use reference type in loop (NFC) (#174379)
Fixes a -Wrange-loop-construct warning.
Added:
Modified:
llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
Removed:
################################################################################
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
index f45092db69cd3..b9f3dad406e86 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
@@ -6302,7 +6302,7 @@ bool SelectionDAGBuilder::EmitFuncArgumentDbgValue(
auto splitMultiRegDbgValue =
[&](ArrayRef<std::pair<Register, TypeSize>> SplitRegs) -> bool {
unsigned Offset = 0;
- for (const auto [Reg, RegSizeInBits] : SplitRegs) {
+ for (const auto &[Reg, RegSizeInBits] : SplitRegs) {
// FIXME: Scalable sizes are not supported in fragment expressions.
if (RegSizeInBits.isScalable())
return false;
More information about the llvm-commits
mailing list