Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/microsoft/GSL.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJordan Maples [MSFT] <49793787+JordanMaples@users.noreply.github.com>2020-02-06 01:41:41 +0300
committerJordan Maples [MSFT] <49793787+JordanMaples@users.noreply.github.com>2020-02-06 01:41:41 +0300
commit45f016d96fe4bdc4c56d521509b88991f667c619 (patch)
treefeec98e6eaddcefd507251c426b092eae83e0cc1 /tests
parentff5f7973a28fc360bfd34af90486d784e48bc384 (diff)
add back capture variable for comparison in span_test
Diffstat (limited to 'tests')
-rw-r--r--tests/span_tests.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/span_tests.cpp b/tests/span_tests.cpp
index c1dbbef..5d9c18b 100644
--- a/tests/span_tests.cpp
+++ b/tests/span_tests.cpp
@@ -1103,11 +1103,11 @@ TEST(span_test, from_array_constructor)
span<int> s = a;
span<int> s2 = b;
#if (__cplusplus > 201402L)
- EXPECT_DEATH([[maybe_unused]] s.begin() == s2.begin(), deathstring);
- EXPECT_DEATH([[maybe_unused]] s.begin() <= s2.begin(), deathstring);
+ EXPECT_DEATH([[maybe_unused]] bool _ = (s.begin() == s2.begin()), deathstring);
+ EXPECT_DEATH([[maybe_unused]] bool _ = (s.begin() <= s2.begin()), deathstring);
#else
- EXPECT_DEATH(s.begin() == s2.begin(), deathstring);
- EXPECT_DEATH(s.begin() <= s2.begin(), deathstring);
+ EXPECT_DEATH(bool _ = (s.begin() == s2.begin()), deathstring);
+ EXPECT_DEATH(bool _ = (s.begin() <= s2.begin()), deathstring);
#endif
}
}