re PR c++/11991 (ICE in cxx_incomplete_type_diagnostic, at cp/typeck2.c:282 when...
authorMark Mitchell <mark@codesourcery.com>
Wed, 17 Sep 2003 23:50:04 +0000 (23:50 +0000)
committerMark Mitchell <mmitchel@gcc.gnu.org>
Wed, 17 Sep 2003 23:50:04 +0000 (23:50 +0000)
PR c++/11991
* g++.dg/rtti/typeid3.C: New test.

From-SVN: r71489

gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/rtti/typeid3.C [new file with mode: 0644]

index 2bd53c546a85d87be7bc1281bcd714af1538f5a6..7bd6e69d6fd6ffae08ba16c5f3918a5aaba419f3 100644 (file)
@@ -1,5 +1,8 @@
 2003-09-17  Mark Mitchell  <mark@codesourcery.com>
 
+       PR c++/11991
+       * g++.dg/rtti/typeid3.C: New test.
+
        PR c++/12266
        * g++.dg/overload/template1.C: New test.
 
diff --git a/gcc/testsuite/g++.dg/rtti/typeid3.C b/gcc/testsuite/g++.dg/rtti/typeid3.C
new file mode 100644 (file)
index 0000000..b36563a
--- /dev/null
@@ -0,0 +1,11 @@
+#include <typeinfo> 
+template <template <class> class T> struct A { 
+    void error() { 
+      typeid(T).name(); // { dg-error "" }
+    } 
+}; 
+template <class T> struct B {}; 
+template void A<B>::error(); // { dg-error "instantiated" }