From: Marek Polacek Date: Tue, 19 Mar 2024 21:15:38 +0000 (-0400) Subject: testsuite: fix target for linkage-1.C X-Git-Tag: basepoints/gcc-15~581 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7a6261332de58fd47283d694d8cd61ea7cdb324c;p=thirdparty%2Fgcc.git testsuite: fix target for linkage-1.C This test fails in C++11 due to: linkage-1.C:3:8: error: 'f' function uses 'auto' type specifier without trailing return type 3 | inline auto f() { | ^~~~ linkage-1.C:3:8: note: deduced return type only available with '-std=c++14' or '-std=gnu++14' Compile it in C++14 thus. gcc/testsuite/ChangeLog: * g++.dg/cpp2a/linkage-1.C: Use target c++14. --- diff --git a/gcc/testsuite/g++.dg/cpp2a/linkage-1.C b/gcc/testsuite/g++.dg/cpp2a/linkage-1.C index 888ed6fa5b59..2b83ffe55b7c 100644 --- a/gcc/testsuite/g++.dg/cpp2a/linkage-1.C +++ b/gcc/testsuite/g++.dg/cpp2a/linkage-1.C @@ -1,4 +1,4 @@ -// { dg-do compile { target c++11 } } +// { dg-do compile { target c++14 } } inline auto f() { struct A {};