summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.pt/crash59.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.pt/crash59.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.pt/crash59.C21
1 files changed, 21 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/crash59.C b/gcc/testsuite/g++.old-deja/g++.pt/crash59.C
new file mode 100644
index 000000000..37a2fc531
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.pt/crash59.C
@@ -0,0 +1,21 @@
+// { dg-do assemble }
+// Copyright (C) 2000 Free Software Foundation, Inc.
+// Contributed by Nathan Sidwell 4 Oct 2000 <nathan@codesourcery.com>
+// Origin: Bug 543 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
+
+// Bug 532. We failed to bail out when tsubsting a _DECL failed
+
+class ATOMSET
+{
+};
+
+template <class T>
+void addConstsTo(const T &container)
+{
+typename T::const_iterator l = 0; // { dg-error "" } no type const_iterator
+}
+
+void tallyConstants()
+{
+addConstsTo(ATOMSET());
+}