public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type
@ 2003-08-19 22:51 bangerth at dealii dot org
2003-08-19 23:13 ` [Bug c++/11987] " pinskia at gcc dot gnu dot org
` (9 more replies)
0 siblings, 10 replies; 11+ messages in thread
From: bangerth at dealii dot org @ 2003-08-19 22:51 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
Summary: ICE/accepts-invalid with inherited nested type
Product: gcc
Version: 3.4
Status: UNCONFIRMED
Keywords: ice-on-invalid-code, accepts-invalid
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: bangerth at dealii dot org
CC: gcc-bugs at gcc dot gnu dot org
This piece of invalid code
----------------------------------------
template <int dim> struct X {
struct I { I(); };
};
template <int dim> struct Y : X<dim> {
typedef typename X<dim>::I I;
};
template <int dim>
Y<dim>::I::I () {} // note: I is nested type in X, not Y!
template struct Y<1>;
------------------------------------------------
ICEs everything up to and including 3.3:
parameter-estimation/libparest> /ices/bangerth/bin/gcc-3.3/bin/g++ -c x.cc
x.cc:10: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
On the other hand, present mainline accepts it, which I think is spurious. So
we traded an ICE for an accepts-invalid.
W.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/11987] ICE/accepts-invalid with inherited nested type
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
@ 2003-08-19 23:13 ` pinskia at gcc dot gnu dot org
2003-08-23 1:23 ` [Bug c++/11987] [3.4 regression] " dhazeghi at yahoo dot com
` (8 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-08-19 23:13 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2003-08-19 23:13:39
date| |
------- Additional Comments From pinskia at gcc dot gnu dot org 2003-08-19 23:13 -------
I can confirm this on the mainline (20030819). GCC stopped ICEing when the new parser came in
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/11987] [3.4 regression] ICE/accepts-invalid with inherited nested type
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
2003-08-19 23:13 ` [Bug c++/11987] " pinskia at gcc dot gnu dot org
@ 2003-08-23 1:23 ` dhazeghi at yahoo dot com
2003-10-24 15:27 ` [Bug c++/11987] [3.4 regression] Accepts-invalid " lerdsuwa at gcc dot gnu dot org
` (7 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: dhazeghi at yahoo dot com @ 2003-08-23 1:23 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
dhazeghi at yahoo dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|ICE/accepts-invalid with |[3.4 regression]
|inherited nested type |ICE/accepts-invalid with
| |inherited nested type
------- Additional Comments From dhazeghi at yahoo dot com 2003-08-23 01:23 -------
I'd say that qualifies as a regression....
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/11987] [3.4 regression] Accepts-invalid with inherited nested type
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
2003-08-19 23:13 ` [Bug c++/11987] " pinskia at gcc dot gnu dot org
2003-08-23 1:23 ` [Bug c++/11987] [3.4 regression] " dhazeghi at yahoo dot com
@ 2003-10-24 15:27 ` lerdsuwa at gcc dot gnu dot org
2004-02-03 14:06 ` [Bug c++/11987] [3.4/3.5 " giovannibajo at libero dot it
` (6 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: lerdsuwa at gcc dot gnu dot org @ 2003-10-24 15:27 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
lerdsuwa at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords|ice-on-invalid-code |
Summary|[3.4 regression] |[3.4 regression] Accepts-
|ICE/accepts-invalid with |invalid with inherited
|inherited nested type |nested type
------- Additional Comments From lerdsuwa at gcc dot gnu dot org 2003-10-24 14:51 -------
Update bug summary since it's only accepts-invalid in 3.4.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/11987] [3.4/3.5 regression] Accepts-invalid with inherited nested type
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
` (2 preceding siblings ...)
2003-10-24 15:27 ` [Bug c++/11987] [3.4 regression] Accepts-invalid " lerdsuwa at gcc dot gnu dot org
@ 2004-02-03 14:06 ` giovannibajo at libero dot it
2004-02-03 14:34 ` bangerth at dealii dot org
` (5 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: giovannibajo at libero dot it @ 2004-02-03 14:06 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From giovannibajo at libero dot it 2004-02-03 14:06 -------
Wolfgang, I'm revisiting this bug.
Y<dim>::I is a typedef for X<dim>::I. The standard does not explicitally
forbids the use of typedef-names as qualifying scope in a constructor
definition, and they are generally allowed for member functions. For instance,
the following is trivially valid:
struct C { C(); };
typedef C D;
D::C() {}
The only limitation I see is [comp.ctor]/3, which says that "a typedef-name
that names a class shall not be used as the identifier in the declarator for a
constructor declaration." but it is referring to the identifier itself, not to
the qualified-id.
Do you agree?
I'm positive that your testcase is indeed valid.
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |giovannibajo at libero dot
| |it
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/11987] [3.4/3.5 regression] Accepts-invalid with inherited nested type
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
` (3 preceding siblings ...)
2004-02-03 14:06 ` [Bug c++/11987] [3.4/3.5 " giovannibajo at libero dot it
@ 2004-02-03 14:34 ` bangerth at dealii dot org
2004-02-28 2:31 ` mmitchel at gcc dot gnu dot org
` (4 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: bangerth at dealii dot org @ 2004-02-03 14:34 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bangerth at dealii dot org 2004-02-03 14:34 -------
Your knowledge in this area is certainly better than mine, so
I trust your judgment.
As one datapoint, though, here is what icc says about my testcase:
g/x> icc -c x.cc -Xc -ansi
x.cc(10): error: "Y<dim>::I" is not a class template
Y<dim>::I::I () {} // note: I is nested type in X, not Y!
^
W.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/11987] [3.4/3.5 regression] Accepts-invalid with inherited nested type
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
` (4 preceding siblings ...)
2004-02-03 14:34 ` bangerth at dealii dot org
@ 2004-02-28 2:31 ` mmitchel at gcc dot gnu dot org
2004-06-12 21:53 ` mmitchel at gcc dot gnu dot org
` (3 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2004-02-28 2:31 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From mmitchel at gcc dot gnu dot org 2004-02-28 02:31 -------
This is a regression, but not very easy to fix, and not terribly harmful.
Therefore, I've pushed the target milestone back to 3.4.1.
--
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|3.4.0 |3.4.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/11987] [3.4/3.5 regression] Accepts-invalid with inherited nested type
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
` (5 preceding siblings ...)
2004-02-28 2:31 ` mmitchel at gcc dot gnu dot org
@ 2004-06-12 21:53 ` mmitchel at gcc dot gnu dot org
2005-04-21 4:58 ` [Bug c++/11987] [3.4/4.0/4.1 " mmitchel at gcc dot gnu dot org
` (2 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2004-06-12 21:53 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From mmitchel at gcc dot gnu dot org 2004-06-12 21:53 -------
Postponed until GCC 3.5.0; I doubt there is an easy fix.
--
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|3.4.1 |3.5.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/11987] [3.4/4.0/4.1 regression] Accepts-invalid with inherited nested type
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
` (6 preceding siblings ...)
2004-06-12 21:53 ` mmitchel at gcc dot gnu dot org
@ 2005-04-21 4:58 ` mmitchel at gcc dot gnu dot org
2005-07-08 1:38 ` mmitchel at gcc dot gnu dot org
2005-09-27 20:58 ` mmitchel at gcc dot gnu dot org
9 siblings, 0 replies; 11+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2005-04-21 4:58 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.0.0 |4.0.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/11987] [3.4/4.0/4.1 regression] Accepts-invalid with inherited nested type
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
` (7 preceding siblings ...)
2005-04-21 4:58 ` [Bug c++/11987] [3.4/4.0/4.1 " mmitchel at gcc dot gnu dot org
@ 2005-07-08 1:38 ` mmitchel at gcc dot gnu dot org
2005-09-27 20:58 ` mmitchel at gcc dot gnu dot org
9 siblings, 0 replies; 11+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2005-07-08 1:38 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.0.1 |4.0.2
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/11987] [3.4/4.0/4.1 regression] Accepts-invalid with inherited nested type
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
` (8 preceding siblings ...)
2005-07-08 1:38 ` mmitchel at gcc dot gnu dot org
@ 2005-09-27 20:58 ` mmitchel at gcc dot gnu dot org
9 siblings, 0 replies; 11+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2005-09-27 20:58 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From mmitchel at gcc dot gnu dot org 2005-09-27 20:58 -------
We're not sure if this is valid or not.
See:
http://gcc.gnu.org/ml/gcc-patches/2005-09/msg01732.html
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11987
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2005-09-27 20:58 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-19 22:51 [Bug c++/11987] New: ICE/accepts-invalid with inherited nested type bangerth at dealii dot org
2003-08-19 23:13 ` [Bug c++/11987] " pinskia at gcc dot gnu dot org
2003-08-23 1:23 ` [Bug c++/11987] [3.4 regression] " dhazeghi at yahoo dot com
2003-10-24 15:27 ` [Bug c++/11987] [3.4 regression] Accepts-invalid " lerdsuwa at gcc dot gnu dot org
2004-02-03 14:06 ` [Bug c++/11987] [3.4/3.5 " giovannibajo at libero dot it
2004-02-03 14:34 ` bangerth at dealii dot org
2004-02-28 2:31 ` mmitchel at gcc dot gnu dot org
2004-06-12 21:53 ` mmitchel at gcc dot gnu dot org
2005-04-21 4:58 ` [Bug c++/11987] [3.4/4.0/4.1 " mmitchel at gcc dot gnu dot org
2005-07-08 1:38 ` mmitchel at gcc dot gnu dot org
2005-09-27 20:58 ` mmitchel 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).