From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11268 invoked by alias); 17 Apr 2012 21:11:43 -0000 Received: (qmail 11229 invoked by uid 22791); 17 Apr 2012 21:11:42 -0000 X-SWARE-Spam-Status: No, hits=-4.3 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00,KHOP_THREADED X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 17 Apr 2012 21:10:54 +0000 From: "fabien at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/52841] [4.7/4.8 Regression] error: type 'Solvable' is not a base type for type 'Resolvable' Date: Tue, 17 Apr 2012 21:11:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Keywords: rejects-valid X-Bugzilla-Severity: normal X-Bugzilla-Who: fabien at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: fabien at gcc dot gnu.org X-Bugzilla-Target-Milestone: 4.7.1 X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2012-04/txt/msg01444.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52841 --- Comment #8 from fabien at gcc dot gnu.org 2012-04-17 21:08:13 UTC --- It is related to alias declarations. It seems that we do not recover properly from a failure in cp_parser_alias_declaration, in the block introduced by this check: "if (!(flags & CP_PARSER_FLAGS_NO_USER_DEFINED_TYPES))", around here: #0 cp_parser_simple_type_specifier (parser=0x7ffff571b738, decl_specs=0x7fffffffdd00, flags=1) at ../../gcc/gcc/cp/parser.c:13651 #1 0x00000000006be5e0 in cp_parser_type_specifier (parser=0x7ffff571b738, flags=1, decl_specs=0x7fffffffdd00, is_declaration=0 '\000', declares_class_or_enum=0x0, is_cv_qualifier=0x7fffffffdcde "") at ../../gcc/gcc/cp/parser.c:13434 #2 0x00000000006c5c96 in cp_parser_type_specifier_seq (parser=0x7ffff571b738, is_declaration=0 '\000', is_trailing_return=0 '\000', type_specifier_seq=0x7fffffffdd00) at ../../gcc/gcc/cp/parser.c:16887 #3 0x00000000006c5a63 in cp_parser_type_id_1 (parser=0x7ffff571b738, is_template_arg=0 '\000', is_trailing_return=0 '\000') at ../../gcc/gcc/cp/parser.c:16771 #4 0x00000000006c5b57 in cp_parser_type_id (parser=0x7ffff571b738) at ../../gcc/gcc/cp/parser.c:16810 #5 0x00000000006c1987 in cp_parser_alias_declaration (parser=0x7ffff571b738) at ../../gcc/gcc/cp/parser.c:15101 I can't find what goes wrong there. The good news is that it seems to work if we return earlier in cp_parser_alias_declaration -- which I think is better --, like in the attached patch. Perhaps Dodji (or Jason) can take a closer look ?