We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6312ab0 commit 01fe546Copy full SHA for 01fe546
libcxx/test/std/utilities/tuple/tuple.tuple/tuple.apply/make_from_tuple.verify.cpp
@@ -18,6 +18,12 @@
18
19
void test() {
20
// expected-error@*:* {{static assertion failed}}
21
+
22
+ // Turns to an error since C++26 (Disallow Binding a Returned Glvalue to a Temporary https://wg21.link/P2748R5).
23
+#if _LIBCPP_STD_VER >= 26
24
// expected-error@*:* {{returning reference to local temporary object}}
25
+#else
26
+ // expected-warning@*:* {{returning reference to local temporary object}}
27
+#endif
28
std::ignore = std::make_from_tuple<const int&>(std::tuple<char>{});
29
}
0 commit comments