Author: David Spickett Date: 2026-01-13T15:02:43Z New Revision: 88500e5a6b71973c38a26c1e70025918bf9609fc
URL: https://github.com/llvm/llvm-project/commit/88500e5a6b71973c38a26c1e70025918bf9609fc DIFF: https://github.com/llvm/llvm-project/commit/88500e5a6b71973c38a26c1e70025918bf9609fc.diff LOG: [lldb][test] Fix warning in DAP unit tests ProtocolTypesTest.cpp:1140:19: warning: loop variable '[value, expected]' creates a copy from type 'std::pair<lldb_dap::protocol::ExceptionBreakMode, llvm::StringRef> const' [-Wrange-loop-construct] for (const auto [value, expected] : test_cases) { Not that it matters because the types are lightweight, but the warning is creating noise in my builds. Added: Modified: lldb/unittests/DAP/ProtocolTypesTest.cpp Removed: ################################################################################ diff --git a/lldb/unittests/DAP/ProtocolTypesTest.cpp b/lldb/unittests/DAP/ProtocolTypesTest.cpp index f842b6c2a20e3..2dd795d28172a 100644 --- a/lldb/unittests/DAP/ProtocolTypesTest.cpp +++ b/lldb/unittests/DAP/ProtocolTypesTest.cpp @@ -1137,7 +1137,7 @@ TEST(ProtocolTypesTest, ExceptionBreakMode) { {ExceptionBreakMode::eExceptionBreakModeUnhandled, "unhandled"}, {ExceptionBreakMode::eExceptionBreakModeUserUnhandled, "userUnhandled"}}; - for (const auto [value, expected] : test_cases) { + for (const auto &[value, expected] : test_cases) { json::Value const serialized = toJSON(value); ASSERT_EQ(serialized.kind(), llvm::json::Value::Kind::String); EXPECT_EQ(serialized.getAsString(), expected); _______________________________________________ lldb-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
