]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
re PR c++/25663 (Trouble parsing nested templated constructor calls)
authorMark Mitchell <mark@codesourcery.com>
Sun, 15 Jan 2006 00:56:50 +0000 (00:56 +0000)
committerMark Mitchell <mmitchel@gcc.gnu.org>
Sun, 15 Jan 2006 00:56:50 +0000 (00:56 +0000)
PR c++/25663
* parser.c (cp_parser_direct_declarator): Use cp_parser_error
instead of error.
PR c++/25663
* g++.dg/template/ctor6.C: New test.

From-SVN: r109713

gcc/cp/ChangeLog
gcc/cp/parser.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/template/ctor6.C [new file with mode: 0644]

index 8c5a33c70439bd4cf9c50d82df58d4964e03be8b..96cf0a954f20c91119ba8a64869b6fe14b0dad78 100644 (file)
@@ -1,3 +1,9 @@
+2006-01-14  Mark Mitchell  <mark@codesourcery.com>
+
+       PR c++/25663
+       * parser.c (cp_parser_direct_declarator): Use cp_parser_error
+       instead of error.
+
 2006-01-13  Jason Merrill  <jason@redhat.com>
 
        * pt.c (check_explicit_specialization): Use CP_DECL_CONTEXT even more.
index 637e183946a5af2a2bfa1e1cf62998628656043c..8e11d43904dbf7cef07fa778d06970728c9b41fc 100644 (file)
@@ -11505,7 +11505,7 @@ cp_parser_direct_declarator (cp_parser* parser,
                         here because we do not have enough
                         information about its original syntactic
                         form.  */
-                     error ("invalid declarator");
+                     cp_parser_error (parser, "invalid declarator");
                      declarator = cp_error_declarator;
                      break;
                    }
index 5567ae32bbaf6aac7f8e022514cc0147651dad4c..bf07e66e2a5c653ef017f2d0df251f9cb2e77df2 100644 (file)
@@ -1,3 +1,8 @@
+2006-01-14  Mark Mitchell  <mark@codesourcery.com>
+
+       PR c++/25663
+       * g++.dg/template/ctor6.C: New test.
+
 2006-01-14  Kazu Hirata  <kazu@codesourcery.com>
 
        PR tree-optimization/25485
diff --git a/gcc/testsuite/g++.dg/template/ctor6.C b/gcc/testsuite/g++.dg/template/ctor6.C
new file mode 100644 (file)
index 0000000..4f21dc9
--- /dev/null
@@ -0,0 +1,11 @@
+// PR c++/25663
+
+template<int> struct A
+{
+  A(int);
+};
+
+void foo()
+{
+  A<0>(A<0>(0));
+}