public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/31516] New: ICE on nested templates
@ 2007-04-09 20:19 reichelt at gcc dot gnu dot org
2007-04-09 23:31 ` [Bug c++/31516] " bangerth at dealii dot org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2007-04-09 20:19 UTC (permalink / raw)
To: gcc-bugs
The following valid code snippet triggers an ICE since at least GCC 2.95.3:
=================================
template<int> struct A
{
template<int> struct B
{
template<int> void foo()
{
struct C { C() {} };
}
};
};
=================================
bug.cc: In member function 'void A<<anonymous> >::B<<anonymous> >::foo()':
bug.cc:7: internal compiler error: tree check: expected class 'type', have
'declaration' (function_decl) in push_template_decl_real, at cp/pt.c:3857
Please submit a full bug report, [etc.]
--
Summary: ICE on nested templates
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Keywords: ice-on-valid-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=31516
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/31516] ICE on nested templates
2007-04-09 20:19 [Bug c++/31516] New: ICE on nested templates reichelt at gcc dot gnu dot org
@ 2007-04-09 23:31 ` bangerth at dealii dot org
2007-04-10 0:23 ` reichelt at gcc dot gnu dot org
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: bangerth at dealii dot org @ 2007-04-09 23:31 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from bangerth at dealii dot org 2007-04-10 00:30 -------
Confirmed, though this appears to work up to and including the 4.1.2
release at least, in contrast to your assertion...
W.
--
bangerth at dealii dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |bangerth at dealii dot org
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2007-04-10 00:30:53
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31516
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/31516] ICE on nested templates
2007-04-09 20:19 [Bug c++/31516] New: ICE on nested templates reichelt at gcc dot gnu dot org
2007-04-09 23:31 ` [Bug c++/31516] " bangerth at dealii dot org
@ 2007-04-10 0:23 ` reichelt at gcc dot gnu dot org
2007-04-10 18:18 ` bangerth at dealii dot org
2007-08-15 15:25 ` pcarlini at suse dot de
3 siblings, 0 replies; 5+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2007-04-10 0:23 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from reichelt at gcc dot gnu dot org 2007-04-10 01:22 -------
Well, it crashes for me:
GCC 2.95.3:
PR31516.cc: In method `A<{anon}>::B<{anon}>::foo()::C::C()':
PR31516.cc:7: ../../../gcc-2.95.3/gcc/cp/pt.c:2493: Expect 't', have
'function_decl'
GCC 3.0.4:
PR31516.cc: In member function `void A<<anonymous> >::B<<anonymous> >::foo()':
PR31516.cc:7: Tree check: expected class 't', have 'd' (function_decl) in
push_template_decl_real, at cp/pt.c:2687
Please submit a full bug report, [etc.]
GCC 3.2.3:
PR31516.cc: In member function `void A<<anonymous> >::B<<anonymous> >::foo()':
PR31516.cc:7: tree check: expected class 't', have 'd' (function_decl) in
push_template_decl_real, at cp/pt.c:2776
Please submit a full bug report, [etc.]
GCC 3.3.6:
PR31516.cc: In member function `void A<<anonymous> >::B<<anonymous> >::foo()':
PR31516.cc:7: internal compiler error: tree check: expected class 't', have 'd'
(function_decl) in push_template_decl_real, at cp/pt.c:2897
Please submit a full bug report, [etc.]
Maybe you don't have checking enabled for the release versions?
--
reichelt at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |ice-checking
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31516
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/31516] ICE on nested templates
2007-04-09 20:19 [Bug c++/31516] New: ICE on nested templates reichelt at gcc dot gnu dot org
2007-04-09 23:31 ` [Bug c++/31516] " bangerth at dealii dot org
2007-04-10 0:23 ` reichelt at gcc dot gnu dot org
@ 2007-04-10 18:18 ` bangerth at dealii dot org
2007-08-15 15:25 ` pcarlini at suse dot de
3 siblings, 0 replies; 5+ messages in thread
From: bangerth at dealii dot org @ 2007-04-10 18:18 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from bangerth at dealii dot org 2007-04-10 19:18 -------
(In reply to comment #2)
> Maybe you don't have checking enabled for the release versions?
That appears to be the case (I thought I had set --enable-checking).
In any case, I see the ICE on the currently maintained release branches,
which is what counts anyway :-)
W.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31516
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/31516] ICE on nested templates
2007-04-09 20:19 [Bug c++/31516] New: ICE on nested templates reichelt at gcc dot gnu dot org
` (2 preceding siblings ...)
2007-04-10 18:18 ` bangerth at dealii dot org
@ 2007-08-15 15:25 ` pcarlini at suse dot de
3 siblings, 0 replies; 5+ messages in thread
From: pcarlini at suse dot de @ 2007-08-15 15:25 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from pcarlini at suse dot de 2007-08-15 15:25 -------
This is a duplicate of 33035 and indeed the latter isn't a regression, I'm
fixing that.
*** This bug has been marked as a duplicate of 33035 ***
--
pcarlini at suse dot de changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |DUPLICATE
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31516
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2007-08-15 15:25 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-04-09 20:19 [Bug c++/31516] New: ICE on nested templates reichelt at gcc dot gnu dot org
2007-04-09 23:31 ` [Bug c++/31516] " bangerth at dealii dot org
2007-04-10 0:23 ` reichelt at gcc dot gnu dot org
2007-04-10 18:18 ` bangerth at dealii dot org
2007-08-15 15:25 ` pcarlini at suse dot de
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).