This was fixed by r12-6025 and is sufficiently different from
noexcept71.C that I think we should add it.
Tested x86_64-pc-linux-gnu, applying to trunk.
PR c++/102338
gcc/testsuite/ChangeLog:
* g++.dg/cpp1y/noexcept2.C: New test.
---
gcc/testsuite/g++.dg/cpp1y/noexcept2.C | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
create mode 100644 gcc/testsuite/g++.dg/cpp1y/noexcept2.C
diff --git a/gcc/testsuite/g++.dg/cpp1y/noexcept2.C
b/gcc/testsuite/g++.dg/cpp1y/noexcept2.C
new file mode 100644
index 00000000000..38dd05cd066
--- /dev/null
+++ b/gcc/testsuite/g++.dg/cpp1y/noexcept2.C
@@ -0,0 +1,20 @@
+// PR c++/102338
+// { dg-do compile { target c++14 } }
+
+struct S {
+ template<typename T>
+ static auto f(T&& t) noexcept {
+ return true;
+ }
+
+ template<typename T, typename... Ts>
+ static auto f(T&& t, Ts&& ... ts) noexcept(noexcept(f(ts...))) {
+ return f(ts...);
+ }
+
+};
+
+int main() {
+ S::f(true, 0, 5u);
+ return 0;
+}
base-commit: 2f34d7ef3d026cf7109b6e6bb2eca14c840e7c71
--
2.34.1