From e2f69e0afe4cd1dd8a1a74193e3fa66f5a89c1d5 Mon Sep 17 00:00:00 2001 From: Frank Dellaert Date: Wed, 25 Jan 2023 21:47:33 -0800 Subject: [PATCH] Forgot [key, value] only works for c++17 --- gtsam/nonlinear/tests/testValues.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gtsam/nonlinear/tests/testValues.cpp b/gtsam/nonlinear/tests/testValues.cpp index 41bd6aead..758d9a5a3 100644 --- a/gtsam/nonlinear/tests/testValues.cpp +++ b/gtsam/nonlinear/tests/testValues.cpp @@ -196,10 +196,10 @@ TEST(Values, basic_functions) values.insert(8, M2); size_t count = 0; - for (const auto& [key, value] : values) { + for (const auto& it : values) { count += 1; - if (key == 2 || key == 4) EXPECT_LONGS_EQUAL(3, value.dim()); - if (key == 6 || key == 8) EXPECT_LONGS_EQUAL(6, value.dim()); + if (it.key == 2 || it.key == 4) EXPECT_LONGS_EQUAL(3, it.value.dim()); + if (it.key == 6 || it.key == 8) EXPECT_LONGS_EQUAL(6, it.value.dim()); } EXPECT_LONGS_EQUAL(4, count);