From 7f8aaa1ae95814217fa81692f08e01781fa5f747 Mon Sep 17 00:00:00 2001 From: Marek Polacek Date: Wed, 24 Apr 2019 21:28:04 +0000 Subject: [PATCH] re PR c++/90236 (bogus error with auto non-type template argument) PR c++/90236 * g++.dg/cpp1z/nontype-auto16.C: New test. From-SVN: r270557 --- gcc/testsuite/ChangeLog | 5 +++++ gcc/testsuite/g++.dg/cpp1z/nontype-auto16.C | 13 +++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 gcc/testsuite/g++.dg/cpp1z/nontype-auto16.C diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 70ffb8d1e1e..115c22088ef 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2019-04-24 Marek Polacek + + PR c++/90236 + * g++.dg/cpp1z/nontype-auto16.C: New test. + 2019-04-24 Jakub Jelinek PR target/90193 diff --git a/gcc/testsuite/g++.dg/cpp1z/nontype-auto16.C b/gcc/testsuite/g++.dg/cpp1z/nontype-auto16.C new file mode 100644 index 00000000000..695bb11d780 --- /dev/null +++ b/gcc/testsuite/g++.dg/cpp1z/nontype-auto16.C @@ -0,0 +1,13 @@ +// PR c++/90236 +// { dg-do compile { target c++17 } } + +struct foo { }; + +template void fnc() { } + +void +test() +{ + static constexpr foo a; + fnc(); +} -- 2.30.2