public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/15427] New: [3.4 regression] valid code results in incomplete type error
@ 2004-05-14 14:42 nick at ilm dot com
2004-05-14 14:46 ` [Bug c++/15427] " nick at ilm dot com
` (7 more replies)
0 siblings, 8 replies; 9+ messages in thread
From: nick at ilm dot com @ 2004-05-14 14:42 UTC (permalink / raw)
To: gcc-bugs
The following code:
template<class T>
struct A
{
T foo;
};
template<class T>
struct B
{
A<int> _squares[2];
};
results in:
>/dept/rnd/vendor/gcc-3.4.0/bin/g++ -c testCornerFinder.C
testCornerFinder.C:10: error: field `_squares' has incomplete type
with gcc-3.4. gcc-3.3 compiles this code correctly. The code
also compiles if the [2] is removed.
-nick
--
Summary: [3.4 regression] valid code results in incomplete type
error
Product: gcc
Version: 3.4.0
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: nick at ilm dot com
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: i686-pc-linux-gnu
GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15427
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/15427] [3.4 regression] valid code results in incomplete type error
2004-05-14 14:42 [Bug c++/15427] New: [3.4 regression] valid code results in incomplete type error nick at ilm dot com
@ 2004-05-14 14:46 ` nick at ilm dot com
2004-05-14 14:53 ` [Bug c++/15427] [3.4/3.5 " pinskia at gcc dot gnu dot org
` (6 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: nick at ilm dot com @ 2004-05-14 14:46 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |rejects-valid
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15427
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/15427] [3.4/3.5 regression] valid code results in incomplete type error
2004-05-14 14:42 [Bug c++/15427] New: [3.4 regression] valid code results in incomplete type error nick at ilm dot com
2004-05-14 14:46 ` [Bug c++/15427] " nick at ilm dot com
@ 2004-05-14 14:53 ` pinskia at gcc dot gnu dot org
2004-05-14 16:54 ` bangerth at dealii dot org
` (5 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-05-14 14:53 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-05-13 21:04 -------
Confirmed.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Known to fail| |3.4.0 3.5.0
Known to work| |3.3.3
Last reconfirmed|0000-00-00 00:00:00 |2004-05-13 21:04:53
date| |
Summary|[3.4 regression] valid code |[3.4/3.5 regression] valid
|results in incomplete type |code results in incomplete
|error |type error
Target Milestone|--- |3.4.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15427
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/15427] [3.4/3.5 regression] valid code results in incomplete type error
2004-05-14 14:42 [Bug c++/15427] New: [3.4 regression] valid code results in incomplete type error nick at ilm dot com
2004-05-14 14:46 ` [Bug c++/15427] " nick at ilm dot com
2004-05-14 14:53 ` [Bug c++/15427] [3.4/3.5 " pinskia at gcc dot gnu dot org
@ 2004-05-14 16:54 ` bangerth at dealii dot org
2004-05-15 17:29 ` giovannibajo at libero dot it
` (4 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: bangerth at dealii dot org @ 2004-05-14 16:54 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bangerth at dealii dot org 2004-05-13 23:24 -------
Indeed, how surprising. Giovanni, wasn't it you who was working on
incomplete type diagnostics?
W.
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |giovannibajo at gcc dot gnu
| |dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15427
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/15427] [3.4/3.5 regression] valid code results in incomplete type error
2004-05-14 14:42 [Bug c++/15427] New: [3.4 regression] valid code results in incomplete type error nick at ilm dot com
` (2 preceding siblings ...)
2004-05-14 16:54 ` bangerth at dealii dot org
@ 2004-05-15 17:29 ` giovannibajo at libero dot it
2004-05-23 11:22 ` mmitchel at gcc dot gnu dot org
` (3 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: giovannibajo at libero dot it @ 2004-05-15 17:29 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From giovannibajo at libero dot it 2004-05-15 00:04 -------
(In reply to comment #2)
> Indeed, how surprising. Giovanni, wasn't it you who was working on
> incomplete type diagnostics?
Yes, but this is unrelated to the work I did.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15427
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/15427] [3.4/3.5 regression] valid code results in incomplete type error
2004-05-14 14:42 [Bug c++/15427] New: [3.4 regression] valid code results in incomplete type error nick at ilm dot com
` (3 preceding siblings ...)
2004-05-15 17:29 ` giovannibajo at libero dot it
@ 2004-05-23 11:22 ` mmitchel at gcc dot gnu dot org
2004-05-23 13:27 ` cvs-commit at gcc dot gnu dot org
` (2 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2004-05-23 11:22 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From mmitchel at gcc dot gnu dot org 2004-05-22 18:09 -------
Working on a fix.
--
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |mark at codesourcery dot com
|dot org |
Status|NEW |ASSIGNED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15427
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/15427] [3.4/3.5 regression] valid code results in incomplete type error
2004-05-14 14:42 [Bug c++/15427] New: [3.4 regression] valid code results in incomplete type error nick at ilm dot com
` (4 preceding siblings ...)
2004-05-23 11:22 ` mmitchel at gcc dot gnu dot org
@ 2004-05-23 13:27 ` cvs-commit at gcc dot gnu dot org
2004-05-23 17:21 ` cvs-commit at gcc dot gnu dot org
2004-05-23 17:52 ` mmitchel at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-05-23 13:27 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2004-05-22 19:17 -------
Subject: Bug 15427
CVSROOT: /cvs/gcc
Module name: gcc
Branch: gcc-3_4-branch
Changes by: mmitchel@gcc.gnu.org 2004-05-22 19:16:53
Modified files:
gcc/cp : ChangeLog class.c typeck.c
gcc/testsuite : ChangeLog
Added files:
gcc/testsuite/g++.dg/inherit: union1.C
gcc/testsuite/g++.dg/template: addr1.C array5.C array6.C
Log message:
PR c++/15507
* g++.dg/inherit/union1.C: New test.
PR c++/15542
* g++.dg/template/addr1.C: New test.
PR c++/15427
* g++.dg/template/array5.C: New test.
PR c++/15287
* g++.dg/template/array6.C: New test.
PR c++/15507
* g++.dg/inherit/union1.C: New test.
PR c++/15542
* g++.dg/template/addr1.C: New test.
PR c++/15427
* g++.dg/template/array5.C: New test.
PR c++/15287
* g++.dg/template/array6.C: New test.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=1.3892.2.100&r2=1.3892.2.101
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/class.c.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=1.595.4.7&r2=1.595.4.8
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/typeck.c.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=1.519.2.14&r2=1.519.2.15
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=1.3389.2.177&r2=1.3389.2.178
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/inherit/union1.C.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=NONE&r2=1.1.2.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/addr1.C.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=NONE&r2=1.1.2.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/array5.C.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=NONE&r2=1.1.2.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/array6.C.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=NONE&r2=1.1.2.1
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15427
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/15427] [3.4/3.5 regression] valid code results in incomplete type error
2004-05-14 14:42 [Bug c++/15427] New: [3.4 regression] valid code results in incomplete type error nick at ilm dot com
` (5 preceding siblings ...)
2004-05-23 13:27 ` cvs-commit at gcc dot gnu dot org
@ 2004-05-23 17:21 ` cvs-commit at gcc dot gnu dot org
2004-05-23 17:52 ` mmitchel at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-05-23 17:21 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2004-05-22 19:28 -------
Subject: Bug 15427
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: mmitchel@gcc.gnu.org 2004-05-22 19:28:31
Modified files:
gcc/cp : ChangeLog class.c typeck.c
gcc/testsuite : ChangeLog
Added files:
gcc/testsuite/g++.dg/inherit: union1.C
gcc/testsuite/g++.dg/template: addr1.C array5.C array6.C
Log message:
PR c++/15507
* class.c (layout_nonempty_base_or_field): Do not try to avoid
layout conflicts for unions.
PR c++/15542
* typeck.c (build_x_unary_op): Instantiate template class
specializations before looking for "operator &".
PR c++/15427
* typeck.c (complete_type): Layout non-dependent array types, even
in templates.
PR c++/15287
* typeck.c (build_unary_op): Do not optimize "&x[y]" when in a
template.
PR c++/15507
* g++.dg/inherit/union1.C: New test.
PR c++/15542
* g++.dg/template/addr1.C: New test.
PR c++/15427
* g++.dg/template/array5.C: New test.
PR c++/15287
* g++.dg/template/array6.C: New test.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/ChangeLog.diff?cvsroot=gcc&r1=1.4050&r2=1.4051
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/class.c.diff?cvsroot=gcc&r1=1.612&r2=1.613
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/typeck.c.diff?cvsroot=gcc&r1=1.542&r2=1.543
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.3769&r2=1.3770
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/inherit/union1.C.diff?cvsroot=gcc&r1=1.1&r2=1.2
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/addr1.C.diff?cvsroot=gcc&r1=1.1&r2=1.2
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/array5.C.diff?cvsroot=gcc&r1=1.1&r2=1.2
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/array6.C.diff?cvsroot=gcc&r1=1.1&r2=1.2
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15427
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/15427] [3.4/3.5 regression] valid code results in incomplete type error
2004-05-14 14:42 [Bug c++/15427] New: [3.4 regression] valid code results in incomplete type error nick at ilm dot com
` (6 preceding siblings ...)
2004-05-23 17:21 ` cvs-commit at gcc dot gnu dot org
@ 2004-05-23 17:52 ` mmitchel at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2004-05-23 17:52 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From mmitchel at gcc dot gnu dot org 2004-05-22 19:30 -------
Fixed in GCC 3.4.1.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15427
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2004-05-22 19:31 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-05-14 14:42 [Bug c++/15427] New: [3.4 regression] valid code results in incomplete type error nick at ilm dot com
2004-05-14 14:46 ` [Bug c++/15427] " nick at ilm dot com
2004-05-14 14:53 ` [Bug c++/15427] [3.4/3.5 " pinskia at gcc dot gnu dot org
2004-05-14 16:54 ` bangerth at dealii dot org
2004-05-15 17:29 ` giovannibajo at libero dot it
2004-05-23 11:22 ` mmitchel at gcc dot gnu dot org
2004-05-23 13:27 ` cvs-commit at gcc dot gnu dot org
2004-05-23 17:21 ` cvs-commit at gcc dot gnu dot org
2004-05-23 17:52 ` 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).