public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* c++/8895: ICE on invalid template default value specification
@ 2002-12-10 15:16 bangerth
  0 siblings, 0 replies; 3+ messages in thread
From: bangerth @ 2002-12-10 15:16 UTC (permalink / raw)
  To: gcc-gnats


>Number:         8895
>Category:       c++
>Synopsis:       ICE on invalid template default value specification
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          ice-on-illegal-code
>Submitter-Id:   net
>Arrival-Date:   Tue Dec 10 15:16:01 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Wolfgang Bangerth
>Release:        unknown-1.0
>Organization:
>Environment:

>Description:
This (illegal) code
-------------------
template <class X, class Y = C<X> >
struct B {
  B(int);
  B(const B<X,Y>&);
};
-------------------
makes present 3.3 crash:
tmp/g> /home/bangerth/bin/gcc-3.3-pre/bin/c++ -c y.cc
y.cc:1: error: parse error before `<' token
y.cc:4: error: `Y' was not declared in this scope
y.cc:4: error: parse error before `&' token
y.cc:4: error: ISO C++ forbids declaration of `B' with no type
y.cc:4: internal compiler error: Speicherzugriffsfehler
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.


gcc2.95 fares a little better:
tmp/g> c++ -c y.cc
y.cc:1: parse error before `<'
y.cc:4: `Y' was not declared in this scope
y.cc:4: parse error before `&'
y.cc:4: ANSI C++ forbids declaration `B' with no type
y.cc:4: confused by earlier errors, bailing out


I don't know whether this is significant enough to
warrant it marking as a regression. Others might 
decide this.

Regards
  Wolfgang
>How-To-Repeat:

>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


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

* Re: c++/8895: ICE on invalid template default value specification
@ 2003-01-12 23:41 reichelt
  0 siblings, 0 replies; 3+ messages in thread
From: reichelt @ 2003-01-12 23:41 UTC (permalink / raw)
  To: bangerth, gcc-bugs, gcc-prs, nobody

Synopsis: ICE on invalid template default value specification

State-Changed-From-To: analyzed->closed
State-Changed-By: reichelt
State-Changed-When: Sun Jan 12 15:41:42 2003
State-Changed-Why:
    The bug is fixed in gcc 3.4-20021230 with the new parser.
    
    We now get the following error message (without ICE):
    
    bug.cc:1: error: expected type-name
    bug.cc:1: error: expected type-name
    bug.cc:1: error: expected `>'
    bug.cc:1: error: expected unqualified-id
    
    (Testcase in preparation.)

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8895


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

* Re: c++/8895: ICE on invalid template default value specification
@ 2002-12-19  6:50 lerdsuwa
  0 siblings, 0 replies; 3+ messages in thread
From: lerdsuwa @ 2002-12-19  6:50 UTC (permalink / raw)
  To: bangerth, gcc-bugs, gcc-prs, nobody

Synopsis: ICE on invalid template default value specification

State-Changed-From-To: open->analyzed
State-Changed-By: lerdsuwa
State-Changed-When: Thu Dec 19 06:50:54 2002
State-Changed-Why:
    Confirmed.  Bug in error recovery.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8895


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

end of thread, other threads:[~2003-01-12 23:41 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-12-10 15:16 c++/8895: ICE on invalid template default value specification bangerth
2002-12-19  6:50 lerdsuwa
2003-01-12 23:41 reichelt

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).