From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1563 invoked by alias); 4 Feb 2014 07:21:16 -0000 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 Received: (qmail 885 invoked by uid 48); 4 Feb 2014 07:21:07 -0000 From: "reichelt at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/60053] New: [c++1y] ICE with auto as member template function parameter Date: Tue, 04 Feb 2014 07:21:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 4.9.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: reichelt at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-02/txt/msg00239.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60053 Bug ID: 60053 Summary: [c++1y] ICE with auto as member template function parameter Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: reichelt at gcc dot gnu.org The following valid code snippet (compiled with "-std=c++1y") triggers an ICE on trunk: =============================================== struct A { void foo(auto); }; void A::foo(auto) {} template struct B { template void bar(auto); }; =============================================== bug.cc:11:2: internal compiler error: in pop_binding, at cp/name-lookup.c:375}; ^ 0x77d96a pop_binding(tree_node*, tree_node*) ../../gcc/gcc/cp/name-lookup.c:375 0x5c3027 poplevel(int, int, int) ../../gcc/gcc/cp/decl.c:744 0x5fce98 end_template_decl() ../../gcc/gcc/cp/pt.c:3799 0x6cb60f cp_parser_template_declaration_after_export ../../gcc/gcc/cp/parser.c:22938 0x6d69b9 cp_parser_declaration ../../gcc/gcc/cp/parser.c:10947 0x6d54a8 cp_parser_declaration_seq_opt ../../gcc/gcc/cp/parser.c:10869 0x6d6d8a cp_parser_translation_unit ../../gcc/gcc/cp/parser.c:4014 0x6d6d8a c_parse_file() ../../gcc/gcc/cp/parser.c:31528 0x7f66d3 c_common_parse_file() ../../gcc/gcc/c-family/c-opts.c:1060 Please submit a full bug report, [etc.] If I just leave out the name "T" of the template parameter, the code compiles fine. This is probably related to PR60052.