This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/60052] New: [c++1y] ICE with auto as member function parameter


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60052

            Bug ID: 60052
           Summary: [c++1y] ICE with auto as member 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) {}

struct B
{
  void bar(auto);
};
==================================

bug.cc:10:11: internal compiler error: Segmentation fault
   void bar(auto);
           ^
0xba9c8f crash_signal
        ../../gcc/gcc/toplev.c:337
0x6ce47b tree_check
        ../../gcc/gcc/tree.h:2708
0x6ce47b synthesize_implicit_template_parm
        ../../gcc/gcc/cp/parser.c:31950
0x6ce47b cp_parser_simple_type_specifier
        ../../gcc/gcc/cp/parser.c:14504
0x6abcdd cp_parser_type_specifier
        ../../gcc/gcc/cp/parser.c:14380
0x6c5400 cp_parser_decl_specifier_seq
        ../../gcc/gcc/cp/parser.c:11547
0x6c79c7 cp_parser_parameter_declaration
        ../../gcc/gcc/cp/parser.c:18432
0x6c8da1 cp_parser_parameter_declaration_list
        ../../gcc/gcc/cp/parser.c:18258
0x6c93f2 cp_parser_parameter_declaration_clause
        ../../gcc/gcc/cp/parser.c:18179
0x6bf3f0 cp_parser_direct_declarator
        ../../gcc/gcc/cp/parser.c:17072
0x6bf3f0 cp_parser_declarator
        ../../gcc/gcc/cp/parser.c:16943
0x6a890d cp_parser_member_declaration
        ../../gcc/gcc/cp/parser.c:20295
0x6abf74 cp_parser_member_specification_opt
        ../../gcc/gcc/cp/parser.c:19976
0x6abf74 cp_parser_class_specifier_1
        ../../gcc/gcc/cp/parser.c:19210
0x6abf74 cp_parser_class_specifier
        ../../gcc/gcc/cp/parser.c:19437
0x6abf74 cp_parser_type_specifier
        ../../gcc/gcc/cp/parser.c:14302
0x6c5400 cp_parser_decl_specifier_seq
        ../../gcc/gcc/cp/parser.c:11547
0x6cbff9 cp_parser_simple_declaration
        ../../gcc/gcc/cp/parser.c:11137
0x6af4b3 cp_parser_block_declaration
        ../../gcc/gcc/cp/parser.c:11086
0x6d67b2 cp_parser_declaration
        ../../gcc/gcc/cp/parser.c:10983
Please submit a full bug report, [etc.]


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]