Message ID | 20231111003846.496197-1-polacek@redhat.com |
---|---|
State | New |
Headers | show |
Series | [pushed] testsuite: fix lambda-decltype3.C in C++11 | expand |
diff --git a/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-decltype3.C b/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-decltype3.C index 7fc157aefb5..2e06e496140 100644 --- a/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-decltype3.C +++ b/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-decltype3.C @@ -21,8 +21,10 @@ void f() { [=] { [](decltype((x)) y) {}; // OK, lambda takes a parameter of type float const& +#if __cpp_init_captures [x=1](decltype((x)) y) { decltype((x)) z = x; // OK, y has type int&, z has type int const& }; +#endif }; }