public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/19497] New: [3.4/4.0 regression] Invalid declaration in template diagnosed too late
@ 2005-01-18 8:51 reichelt at gcc dot gnu dot org
2005-01-18 14:01 ` [Bug c++/19497] " pinskia at gcc dot gnu dot org
` (6 more replies)
0 siblings, 7 replies; 8+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2005-01-18 8:51 UTC (permalink / raw)
To: gcc-bugs
The following invalid code snippet is rejected since gcc 3.4.0.
============================
template<int> struct A
{
A::A;
};
============================
It's rejected if I instantiate the template, but not at definition time.
--
Summary: [3.4/4.0 regression] Invalid declaration in template
diagnosed too late
Product: gcc
Version: 4.0.0
Status: UNCONFIRMED
Keywords: accepts-invalid, monitored
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: reichelt at gcc dot gnu dot org
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19497
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/19497] [3.4/4.0 regression] Invalid declaration in template diagnosed too late
2005-01-18 8:51 [Bug c++/19497] New: [3.4/4.0 regression] Invalid declaration in template diagnosed too late reichelt at gcc dot gnu dot org
@ 2005-01-18 14:01 ` pinskia at gcc dot gnu dot org
2005-01-18 14:43 ` pinskia at gcc dot gnu dot org
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-01-18 14:01 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |3.4.4
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19497
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/19497] [3.4/4.0 regression] Invalid declaration in template diagnosed too late
2005-01-18 8:51 [Bug c++/19497] New: [3.4/4.0 regression] Invalid declaration in template diagnosed too late reichelt at gcc dot gnu dot org
2005-01-18 14:01 ` [Bug c++/19497] " pinskia at gcc dot gnu dot org
@ 2005-01-18 14:43 ` pinskia at gcc dot gnu dot org
2005-02-14 18:53 ` nathan at gcc dot gnu dot org
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-01-18 14:43 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-01-18 14:28 -------
: Search converges between 2002-12-14-trunk (#159) and 2002-12-29-trunk (#160).
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2005-01-18 14:28:09
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19497
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/19497] [3.4/4.0 regression] Invalid declaration in template diagnosed too late
2005-01-18 8:51 [Bug c++/19497] New: [3.4/4.0 regression] Invalid declaration in template diagnosed too late reichelt at gcc dot gnu dot org
2005-01-18 14:01 ` [Bug c++/19497] " pinskia at gcc dot gnu dot org
2005-01-18 14:43 ` pinskia at gcc dot gnu dot org
@ 2005-02-14 18:53 ` nathan at gcc dot gnu dot org
2005-05-19 17:36 ` [Bug c++/19497] [3.4/4.0/4.1 " mmitchel at gcc dot gnu dot org
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: nathan at gcc dot gnu dot org @ 2005-02-14 18:53 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |nathan at gcc dot gnu dot
|dot org |org
Status|NEW |ASSIGNED
Last reconfirmed|2005-01-18 14:28:09 |2005-02-14 13:49:24
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19497
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/19497] [3.4/4.0/4.1 regression] Invalid declaration in template diagnosed too late
2005-01-18 8:51 [Bug c++/19497] New: [3.4/4.0 regression] Invalid declaration in template diagnosed too late reichelt at gcc dot gnu dot org
` (2 preceding siblings ...)
2005-02-14 18:53 ` nathan at gcc dot gnu dot org
@ 2005-05-19 17:36 ` mmitchel at gcc dot gnu dot org
2005-06-08 11:49 ` cvs-commit at gcc dot gnu dot org
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2005-05-19 17:36 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|3.4.4 |3.4.5
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19497
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/19497] [3.4/4.0/4.1 regression] Invalid declaration in template diagnosed too late
2005-01-18 8:51 [Bug c++/19497] New: [3.4/4.0 regression] Invalid declaration in template diagnosed too late reichelt at gcc dot gnu dot org
` (3 preceding siblings ...)
2005-05-19 17:36 ` [Bug c++/19497] [3.4/4.0/4.1 " mmitchel at gcc dot gnu dot org
@ 2005-06-08 11:49 ` cvs-commit at gcc dot gnu dot org
2005-06-08 11:51 ` nathan at gcc dot gnu dot org
2005-06-08 12:42 ` pinskia at gcc dot gnu dot org
6 siblings, 0 replies; 8+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2005-06-08 11:49 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-06-08 11:49 -------
Subject: Bug 19497
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: nathan@gcc.gnu.org 2005-06-08 11:49:24
Modified files:
gcc/cp : ChangeLog class.c cp-tree.def cp-tree.h
cxx-pretty-print.c name-lookup.c name-lookup.h
pt.c search.c semantics.c
gcc/testsuite : ChangeLog
Added files:
gcc/testsuite/g++.dg/inherit: using5.C using6.C
Log message:
cp:
PR c++/19497
* cp-tree.def (USING_DECL): Update documentation.
* cp-tree.h (DECL_DEPENDENT_P): New.
(USING_DECL_DECLS, USING_DECL_SCOPE): New.
* class.c (handle_using_decl): Move most of the processing to ...
* name-lookup.c (do_class_using_decl): ... here. Make stricter.
(push_using_decl): Use USING_DECL_SCOPE.
(cp_emit_debug_info_for_using): Make extern.
* cxx-pretty-print.c (pp_cxx_statement) <USING_DECL case>: Adjust.
* name-lookup.h (cp_emit_debug_info_for_using): Declare.
* pt.c (tsubst_decl) <USING_DECL case>: Use do_class_using_decl
when tsubsting.
(tsubst_expr): Use USING_DECL_SCOPE.
* search.c (lookup_field_1): Use DECL_DEPENDENT_P.
* semantics.c (finish_member_declaration): Likewise.
testsuite:
PR c++/19497
* g++.dg/inherit/using5.C: New.
* g++.dg/inherit/using6.C: New.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/ChangeLog.diff?cvsroot=gcc&r1=1.4782&r2=1.4783
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/class.c.diff?cvsroot=gcc&r1=1.719&r2=1.720
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/cp-tree.def.diff?cvsroot=gcc&r1=1.104&r2=1.105
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/cp-tree.h.diff?cvsroot=gcc&r1=1.1143&r2=1.1144
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/cxx-pretty-print.c.diff?cvsroot=gcc&r1=1.34&r2=1.35
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/name-lookup.c.diff?cvsroot=gcc&r1=1.122&r2=1.123
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/name-lookup.h.diff?cvsroot=gcc&r1=1.40&r2=1.41
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/pt.c.diff?cvsroot=gcc&r1=1.1004&r2=1.1005
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/search.c.diff?cvsroot=gcc&r1=1.346&r2=1.347
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/semantics.c.diff?cvsroot=gcc&r1=1.474&r2=1.475
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.5613&r2=1.5614
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/inherit/using5.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/inherit/using6.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19497
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/19497] [3.4/4.0/4.1 regression] Invalid declaration in template diagnosed too late
2005-01-18 8:51 [Bug c++/19497] New: [3.4/4.0 regression] Invalid declaration in template diagnosed too late reichelt at gcc dot gnu dot org
` (4 preceding siblings ...)
2005-06-08 11:49 ` cvs-commit at gcc dot gnu dot org
@ 2005-06-08 11:51 ` nathan at gcc dot gnu dot org
2005-06-08 12:42 ` pinskia at gcc dot gnu dot org
6 siblings, 0 replies; 8+ messages in thread
From: nathan at gcc dot gnu dot org @ 2005-06-08 11:51 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From nathan at gcc dot gnu dot org 2005-06-08 11:51 -------
2005-06-08 Nathan Sidwell <nathan@codesourcery.com>
PR c++/19497
* cp-tree.def (USING_DECL): Update documentation.
* cp-tree.h (DECL_DEPENDENT_P): New.
(USING_DECL_DECLS, USING_DECL_SCOPE): New.
* class.c (handle_using_decl): Move most of the processing to ...
* name-lookup.c (do_class_using_decl): ... here. Make stricter.
(push_using_decl): Use USING_DECL_SCOPE.
(cp_emit_debug_info_for_using): Make extern.
* cxx-pretty-print.c (pp_cxx_statement) <USING_DECL case>: Adjust.
* name-lookup.h (cp_emit_debug_info_for_using): Declare.
* pt.c (tsubst_decl) <USING_DECL case>: Use do_class_using_decl
when tsubsting.
(tsubst_expr): Use USING_DECL_SCOPE.
* search.c (lookup_field_1): Use DECL_DEPENDENT_P.
* semantics.c (finish_member_declaration): Likewise.
Fixed mainline, will not fix on 4.0
--
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19497
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug c++/19497] [3.4/4.0/4.1 regression] Invalid declaration in template diagnosed too late
2005-01-18 8:51 [Bug c++/19497] New: [3.4/4.0 regression] Invalid declaration in template diagnosed too late reichelt at gcc dot gnu dot org
` (5 preceding siblings ...)
2005-06-08 11:51 ` nathan at gcc dot gnu dot org
@ 2005-06-08 12:42 ` pinskia at gcc dot gnu dot org
6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-06-08 12:42 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Known to work| |4.1.0
Target Milestone|3.4.5 |4.1.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19497
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2005-06-08 12:42 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-01-18 8:51 [Bug c++/19497] New: [3.4/4.0 regression] Invalid declaration in template diagnosed too late reichelt at gcc dot gnu dot org
2005-01-18 14:01 ` [Bug c++/19497] " pinskia at gcc dot gnu dot org
2005-01-18 14:43 ` pinskia at gcc dot gnu dot org
2005-02-14 18:53 ` nathan at gcc dot gnu dot org
2005-05-19 17:36 ` [Bug c++/19497] [3.4/4.0/4.1 " mmitchel at gcc dot gnu dot org
2005-06-08 11:49 ` cvs-commit at gcc dot gnu dot org
2005-06-08 11:51 ` nathan at gcc dot gnu dot org
2005-06-08 12:42 ` 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).