From c01b22f12291691d1ce89f82211f00eae4398e18 Mon Sep 17 00:00:00 2001
From: Marek Polacek <polacek@redhat.com>
Date: Mon, 10 Aug 2020 19:57:27 -0400
Subject: [PATCH] c++: Add unfixed test [PR88003]

Now that dg-ice is available, let's try it out.

gcc/testsuite/ChangeLog:

	PR c++/88003
	* g++.dg/cpp1y/auto-fn61.C: New test.
---
 gcc/testsuite/g++.dg/cpp1y/auto-fn61.C | 13 +++++++++++++
 1 file changed, 13 insertions(+)
 create mode 100644 gcc/testsuite/g++.dg/cpp1y/auto-fn61.C

diff --git a/gcc/testsuite/g++.dg/cpp1y/auto-fn61.C b/gcc/testsuite/g++.dg/cpp1y/auto-fn61.C
new file mode 100644
index 000000000000..c24c3b85d782
--- /dev/null
+++ b/gcc/testsuite/g++.dg/cpp1y/auto-fn61.C
@@ -0,0 +1,13 @@
+// PR c++/88003
+// { dg-do compile { target c++14 } }
+// { dg-ice "poplevel_class" }
+
+auto test() {
+  struct O {
+    struct N;
+  };
+  return O();
+}
+
+typedef decltype(test()) TN;
+struct TN::N {};
-- 
GitLab