public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/13648] New: [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression
@ 2004-01-11 21:27 bryner at brianryner dot com
2004-01-11 21:29 ` [Bug c++/13648] " bryner at brianryner dot com
` (5 more replies)
0 siblings, 6 replies; 7+ messages in thread
From: bryner at brianryner dot com @ 2004-01-11 21:27 UTC (permalink / raw)
To: gcc-bugs
This appears to be a new regression on the tree-ssa branch. Writing:
const int i = offsetof(A, b.c);
gives this error:
error: `.' cannot appear in a constant-expression
The problem also appears to be C++-specific.
--
Summary: [tree-ssa] offsetof() with a nested struct member fails
to compile in a constant-expression
Product: gcc
Version: tree-ssa
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: bryner at brianryner dot com
CC: gcc-bugs at gcc dot gnu dot org
GCC host triplet: i686-pc-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13648
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/13648] [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression
2004-01-11 21:27 [Bug c++/13648] New: [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression bryner at brianryner dot com
2004-01-11 21:29 ` [Bug c++/13648] " bryner at brianryner dot com
@ 2004-01-11 21:29 ` bryner at brianryner dot com
2004-01-11 21:38 ` pinskia at gcc dot gnu dot org
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: bryner at brianryner dot com @ 2004-01-11 21:29 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bryner at brianryner dot com 2004-01-11 21:29 -------
Created an attachment (id=5458)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=5458&action=view)
testcase
$ c++ -c -o test_offsetof.o test_offsetof.cpp
test_offsetof.cpp:11: error: `.' cannot appear in a constant-expression
$ c++ -v
Reading specs from /usr/gcc-ssa/lib/gcc/i686-pc-linux-gnu/3.5-tree-ssa/specs
Configured with: ../gcc/configure --prefix=/usr/gcc-ssa --enable-shared
--enable-threads=posix --disable-checking --with-system-zlib
--enable-__cxa_atexit --enable-languages=c,c++ --host=i686-pc-linux-gnu
Thread model: posix
gcc version 3.5-tree-ssa 20040110 (merged 20040102)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13648
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/13648] [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression
2004-01-11 21:27 [Bug c++/13648] New: [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression bryner at brianryner dot com
@ 2004-01-11 21:29 ` bryner at brianryner dot com
2004-01-11 21:29 ` bryner at brianryner dot com
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: bryner at brianryner dot com @ 2004-01-11 21:29 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |rejects-valid
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13648
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/13648] [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression
2004-01-11 21:27 [Bug c++/13648] New: [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression bryner at brianryner dot com
2004-01-11 21:29 ` [Bug c++/13648] " bryner at brianryner dot com
2004-01-11 21:29 ` bryner at brianryner dot com
@ 2004-01-11 21:38 ` pinskia at gcc dot gnu dot org
2004-01-11 21:43 ` bryner at brianryner dot com
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-01-11 21:38 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-01-11 21:38 -------
A known bug, which will be fixed with a merge from the mainline.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2004-01-11 21:38:18
date| |
Target Milestone|--- |tree-ssa
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13648
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/13648] [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression
2004-01-11 21:27 [Bug c++/13648] New: [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression bryner at brianryner dot com
` (2 preceding siblings ...)
2004-01-11 21:38 ` pinskia at gcc dot gnu dot org
@ 2004-01-11 21:43 ` bryner at brianryner dot com
2004-01-23 17:44 ` [Bug c++/13648] [tree-ssa] [merge] " pinskia at gcc dot gnu dot org
2004-01-30 18:37 ` pinskia at gcc dot gnu dot org
5 siblings, 0 replies; 7+ messages in thread
From: bryner at brianryner dot com @ 2004-01-11 21:43 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bryner at brianryner dot com 2004-01-11 21:43 -------
Hm... the fix was in cp/parser.c rev 1.145 on the mainline (2004/01/05), but as
of tree-ssa-20020619-merge-20040110, the fix is not on the ssa branch.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13648
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/13648] [tree-ssa] [merge] offsetof() with a nested struct member fails to compile in a constant-expression
2004-01-11 21:27 [Bug c++/13648] New: [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression bryner at brianryner dot com
` (3 preceding siblings ...)
2004-01-11 21:43 ` bryner at brianryner dot com
@ 2004-01-23 17:44 ` pinskia at gcc dot gnu dot org
2004-01-30 18:37 ` pinskia at gcc dot gnu dot org
5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-01-23 17:44 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-01-23 17:44 -------
You and aph are working on the next merge.
--
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |dnovillo at gcc dot gnu dot
|dot org |org
Status|NEW |ASSIGNED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13648
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/13648] [tree-ssa] [merge] offsetof() with a nested struct member fails to compile in a constant-expression
2004-01-11 21:27 [Bug c++/13648] New: [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression bryner at brianryner dot com
` (4 preceding siblings ...)
2004-01-23 17:44 ` [Bug c++/13648] [tree-ssa] [merge] " pinskia at gcc dot gnu dot org
@ 2004-01-30 18:37 ` pinskia at gcc dot gnu dot org
5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-01-30 18:37 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-01-30 18:37 -------
Fixed by the merge.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13648
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2004-01-30 18:37 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-01-11 21:27 [Bug c++/13648] New: [tree-ssa] offsetof() with a nested struct member fails to compile in a constant-expression bryner at brianryner dot com
2004-01-11 21:29 ` [Bug c++/13648] " bryner at brianryner dot com
2004-01-11 21:29 ` bryner at brianryner dot com
2004-01-11 21:38 ` pinskia at gcc dot gnu dot org
2004-01-11 21:43 ` bryner at brianryner dot com
2004-01-23 17:44 ` [Bug c++/13648] [tree-ssa] [merge] " pinskia at gcc dot gnu dot org
2004-01-30 18:37 ` 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).