re PR c++/79590 (ICE (internal compiler error) in nothrow_spec_p with generic lambda...
authorPaolo Carlini <paolo.carlini@oracle.com>
Mon, 2 Oct 2017 22:02:03 +0000 (22:02 +0000)
committerPaolo Carlini <paolo@gcc.gnu.org>
Mon, 2 Oct 2017 22:02:03 +0000 (22:02 +0000)
2017-10-02  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/79590
* g++.dg/cpp1y/lambda-generic-noexcept1.C: New.

From-SVN: r253369

gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/cpp1y/lambda-generic-noexcept1.C [new file with mode: 0644]

index e678265bdd013f218fc9f67edc82751f8ce6d082..aeaa357c2e56bd1aad9705a01f91869792374285 100644 (file)
@@ -1,3 +1,8 @@
+2017-10-02  Paolo Carlini  <paolo.carlini@oracle.com>
+
+       PR c++/79590
+       * g++.dg/cpp1y/lambda-generic-noexcept1.C: New.
+
 2017-10-02  Paolo Carlini  <paolo.carlini@oracle.com>
 
        PR c++/79005
diff --git a/gcc/testsuite/g++.dg/cpp1y/lambda-generic-noexcept1.C b/gcc/testsuite/g++.dg/cpp1y/lambda-generic-noexcept1.C
new file mode 100644 (file)
index 0000000..082aff9
--- /dev/null
@@ -0,0 +1,10 @@
+// PR c++/79590
+// { dg-do compile { target c++14 } }
+
+auto f = [](auto x) noexcept(noexcept(x)) { };
+
+int main()
+{
+  [](auto x) noexcept(noexcept(x)) { } (0);
+  [](auto) noexcept(noexcept(0)) { } (0);
+}