The following invalid code snippet triggers an ICE since GCC 3.4.0:

=================================================
struct A
{
  template<template<int> class B> struct B<0>;
};
=================================================

bug.cc:3: internal compiler error: tree check: expected record_type or
union_type or qual_union_type, have bound_template_template_parm in
finish_member_template_decl, at cp/pt.c:228
Please submit a full bug report, [etc.]

Before, the code was wrongly accepted. (The fact that in-class specializations
are allowed at all is tracked in PR 28300.)


-- 
           Summary: [4.0/4.1/4.2 regression] ICE on invalid in-class
                    specialization
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Keywords: ice-on-invalid-code, monitored
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: reichelt at gcc dot gnu dot org


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

Reply via email to