This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: C++ PATCH for c++/58170 (ICE with alias template)
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Jason Merrill <jason at redhat dot com>
- Cc: gcc-patches List <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 3 Mar 2014 10:38:13 +0100
- Subject: Re: C++ PATCH for c++/58170 (ICE with alias template)
- Authentication-results: sourceware.org; auth=none
- References: <53083A38 dot 7080300 at redhat dot com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Sat, Feb 22, 2014 at 12:48:40AM -0500, Jason Merrill wrote:
> There's no reason why we wouldn't check for dependent scopes when
> parsing the target of an alias declaration, and indeed not doing so
> led to the ICE here.
>
> The rest of the patch improves the diagnostic for this testcase (and
> some others).
>
> Tested x86_64-pc-linux-gnu, applying to trunk. Also applying the
> cp_parser_type_name hunk to 4.8.
This broke the obj-c++.dg/invalid-method-2.mm testcase, fixed thusly,
applied as obvious to the trunk:
2014-03-03 Jakub Jelinek <jakub@redhat.com>
PR objc++/60398
* obj-c++.dg/invalid-method-2.mm: Adjust dg-error regexps.
--- gcc/testsuite/obj-c++.dg/invalid-method-2.mm.jj 2012-11-15 18:21:44.000000000 +0100
+++ gcc/testsuite/obj-c++.dg/invalid-method-2.mm 2014-03-03 10:26:50.333818063 +0100
@@ -7,11 +7,11 @@
@end
@implementation MyClass
-- (x) method /* { dg-error "expected" } */
+- (x) method /* { dg-error "expected|type" } */
{
return 0;
}
-- (id) method2: (x)argument /* { dg-error "expected" } */
+- (id) method2: (x)argument /* { dg-error "expected|type" } */
{
return 0;
}
Jakub