public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/26122]  New: [4.0/4.1/4.2 regression] Pure specifiers for templates causing trouble
@ 2006-02-06 12:25 reichelt at gcc dot gnu dot org
  2006-02-06 12:46 ` [Bug c++/26122] " pinskia at gcc dot gnu dot org
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2006-02-06 12:25 UTC (permalink / raw)
  To: gcc-bugs

The following invalid code snippet is accepted by GCC since at least
GCC 2.95.3:

====================================
struct A
{
    template<int> void foo() = 0;
};
====================================


A similar code snippet causes an ICE since GCC 4.0.0:

====================================
struct A
{
    template<int> void foo() = 1;
};
====================================

  bug.cc:3: internal compiler error: in grokfield, at cp/decl2.c:899
  Please submit a full bug report, [etc.]

It was rejected before, but only because the pure specifier was malformed,
and not because it was present at all:

  bug.cc:3: error: invalid initializer for virtual method `void A::foo()'


-- 
           Summary: [4.0/4.1/4.2 regression] Pure specifiers for templates
                    causing trouble
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Keywords: ice-on-invalid-code, accepts-invalid, 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=26122


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2007-03-03 21:54 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-02-06 12:25 [Bug c++/26122] New: [4.0/4.1/4.2 regression] Pure specifiers for templates causing trouble reichelt at gcc dot gnu dot org
2006-02-06 12:46 ` [Bug c++/26122] " pinskia at gcc dot gnu dot org
2006-02-06 15:14 ` reichelt at gcc dot gnu dot org
2006-02-14  9:00 ` mmitchel at gcc dot gnu dot org
2006-02-18  9:51 ` mmitchel at gcc dot gnu dot org
2006-02-24  0:30 ` mmitchel at gcc dot gnu dot org
2006-04-11 23:00 ` mmitchel at gcc dot gnu dot org
2006-04-12  1:18 ` mmitchel at gcc dot gnu dot org
2006-04-12  1:19 ` mmitchel at gcc dot gnu dot org
2006-05-17 21:39 ` mmitchel at gcc dot gnu dot org
2006-05-17 21:43 ` [Bug c++/26122] [4.0/4.1 " mmitchel at gcc dot gnu dot org
2007-03-03 21:54 ` pinskia at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).