public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
@ 2007-04-29 11:11 reichelt at gcc dot gnu dot org
2007-04-29 11:11 ` [Bug c++/31749] " reichelt at gcc dot gnu dot org
` (13 more replies)
0 siblings, 14 replies; 15+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2007-04-29 11:11 UTC (permalink / raw)
To: gcc-bugs
The following invalid code snippet triggers a segfault since GCC 3.1:
========================
namespace std
{
union abort;
}
void abort();
using std::abort;
========================
bug.cc:8: internal compiler error: Segmentation fault
Please submit a full bug report, [etc.]
Compiling the code with "-fno-builtin" yields:
bug.cc:8: error: 'abort' is already declared in this scope
A slightly different testcase triggers the following ICE:
========================
namespace std
{
union abort;
}
union abort;
using std::abort;
========================
bug.cc:8: internal compiler error: tree check: expected class 'type', have
'declaration' (type_decl) in comptypes, at cp/typeck.c:1115
Please submit a full bug report, [etc.]
--
Summary: [4.1/4.2/4.3 regression] ICE with invalid redeclaration
of builtin
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Keywords: ice-on-invalid-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=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
@ 2007-04-29 11:11 ` reichelt at gcc dot gnu dot org
2007-04-30 18:54 ` mmitchel at gcc dot gnu dot org
` (12 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2007-04-29 11:11 UTC (permalink / raw)
To: gcc-bugs
--
reichelt at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |4.1.3
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
2007-04-29 11:11 ` [Bug c++/31749] " reichelt at gcc dot gnu dot org
@ 2007-04-30 18:54 ` mmitchel at gcc dot gnu dot org
2007-04-30 21:47 ` aaw at google dot com
` (11 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2007-04-30 18:54 UTC (permalink / raw)
To: gcc-bugs
--
mmitchel at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P2
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
2007-04-29 11:11 ` [Bug c++/31749] " reichelt at gcc dot gnu dot org
2007-04-30 18:54 ` mmitchel at gcc dot gnu dot org
@ 2007-04-30 21:47 ` aaw at google dot com
2007-04-30 23:25 ` aaw at google dot com
` (10 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: aaw at google dot com @ 2007-04-30 21:47 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from aaw at google dot com 2007-04-30 22:47 -------
The first code snippet compiles fine with the trunk and gcc-4.1.1. Volker, are
you sure the code snippet is correct?
The second snippet does indeed generate the specified error.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (2 preceding siblings ...)
2007-04-30 21:47 ` aaw at google dot com
@ 2007-04-30 23:25 ` aaw at google dot com
2007-05-22 21:41 ` aaw at gcc dot gnu dot org
` (9 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: aaw at google dot com @ 2007-04-30 23:25 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from aaw at google dot com 2007-05-01 00:24 -------
Never mind. The first snippet triggers the specified error as well. Not quite
sure what I did...
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (3 preceding siblings ...)
2007-04-30 23:25 ` aaw at google dot com
@ 2007-05-22 21:41 ` aaw at gcc dot gnu dot org
2007-08-06 15:13 ` pinskia at gcc dot gnu dot org
` (8 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: aaw at gcc dot gnu dot org @ 2007-05-22 21:41 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from aaw at gcc dot gnu dot org 2007-05-22 22:41 -------
Assigning to myself since I now have write access to Bugzilla.
--
aaw at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |aaw at gcc dot gnu dot org
|dot org |
Status|UNCONFIRMED |ASSIGNED
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2007-05-22 22:41:08
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (4 preceding siblings ...)
2007-05-22 21:41 ` aaw at gcc dot gnu dot org
@ 2007-08-06 15:13 ` pinskia at gcc dot gnu dot org
2007-08-06 21:24 ` aaw at gcc dot gnu dot org
` (7 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-08-06 15:13 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from pinskia at gcc dot gnu dot org 2007-08-06 15:12 -------
I no longer get a segfault for the trunk for the first testcase.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (5 preceding siblings ...)
2007-08-06 15:13 ` pinskia at gcc dot gnu dot org
@ 2007-08-06 21:24 ` aaw at gcc dot gnu dot org
2007-08-06 23:17 ` aaw at gcc dot gnu dot org
` (6 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: aaw at gcc dot gnu dot org @ 2007-08-06 21:24 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from aaw at gcc dot gnu dot org 2007-08-06 21:24 -------
No segfault, but it does give an "is already declared in this scope" error.
Contrary to the claim in the initial bug submission, this is valid code.
>From paragraph 10, section 7.3.3 of the C++ standard:
Since a using-declaration is a declaration, the restrictions on declarations of
the same name in the same declarative region (3.3) also apply to
using-declarations.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (6 preceding siblings ...)
2007-08-06 21:24 ` aaw at gcc dot gnu dot org
@ 2007-08-06 23:17 ` aaw at gcc dot gnu dot org
2007-08-07 19:15 ` patchapp at dberlin dot org
` (5 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: aaw at gcc dot gnu dot org @ 2007-08-06 23:17 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from aaw at gcc dot gnu dot org 2007-08-06 23:17 -------
Created an attachment (id=14030)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14030&action=view)
Fix for PR 31749.
This patches fixes this PR and includes some ambiguous decl cleanup as well.
Submission pending completion of full testsuite.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (7 preceding siblings ...)
2007-08-06 23:17 ` aaw at gcc dot gnu dot org
@ 2007-08-07 19:15 ` patchapp at dberlin dot org
2007-08-17 21:43 ` aaw at gcc dot gnu dot org
` (4 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: patchapp at dberlin dot org @ 2007-08-07 19:15 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from patchapp at dberlin dot org 2007-08-07 19:15 -------
Subject: Bug number PR c++/31749
A patch for this bug has been added to the patch tracker.
The mailing list url for the patch is
http://gcc.gnu.org/ml/gcc-patches/2007-08/msg00452.html
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (8 preceding siblings ...)
2007-08-07 19:15 ` patchapp at dberlin dot org
@ 2007-08-17 21:43 ` aaw at gcc dot gnu dot org
2007-08-18 6:26 ` aaw at gcc dot gnu dot org
` (3 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: aaw at gcc dot gnu dot org @ 2007-08-17 21:43 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from aaw at gcc dot gnu dot org 2007-08-17 21:42 -------
Subject: Bug 31749
Author: aaw
Date: Fri Aug 17 21:42:38 2007
New Revision: 127600
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=127600
Log:
PR c++/31749
gcc/cp/
* name-lookup.c (do_nonmember_using_decl): Shift implicit type
declarations into appropriate slots for comparison. Fix type
comparison.
gcc/testsuite/
* g++.dg/lookup/builtin3.C: New test.
* g++.dg/lookup/builtin4.C: New test.
* g++.dg/lookup/using19.C: New test.
Added:
trunk/gcc/testsuite/g++.dg/lookup/builtin3.C
trunk/gcc/testsuite/g++.dg/lookup/builtin4.C
trunk/gcc/testsuite/g++.dg/lookup/using19.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/name-lookup.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (9 preceding siblings ...)
2007-08-17 21:43 ` aaw at gcc dot gnu dot org
@ 2007-08-18 6:26 ` aaw at gcc dot gnu dot org
2007-08-18 9:07 ` [Bug c++/31749] [4.1/4.2 " pinskia at gcc dot gnu dot org
` (2 subsequent siblings)
13 siblings, 0 replies; 15+ messages in thread
From: aaw at gcc dot gnu dot org @ 2007-08-18 6:26 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from aaw at gcc dot gnu dot org 2007-08-18 06:26 -------
Fixed by change 127600.
--
aaw at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.1/4.2 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (10 preceding siblings ...)
2007-08-18 6:26 ` aaw at gcc dot gnu dot org
@ 2007-08-18 9:07 ` pinskia at gcc dot gnu dot org
2008-07-04 22:02 ` [Bug c++/31749] [4.2 " jsm28 at gcc dot gnu dot org
2009-03-30 21:45 ` jsm28 at gcc dot gnu dot org
13 siblings, 0 replies; 15+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-08-18 9:07 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from pinskia at gcc dot gnu dot org 2007-08-18 09:07 -------
No, this was only fixed for the trunk, this is still not fixed for the 4.2
branch or 4.1 branch (it is a regression after all).
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|FIXED |
Summary|[4.1/4.2/4.3 regression] ICE|[4.1/4.2 regression] ICE
|with invalid redeclaration |with invalid redeclaration
|of builtin |of builtin
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.2 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (11 preceding siblings ...)
2007-08-18 9:07 ` [Bug c++/31749] [4.1/4.2 " pinskia at gcc dot gnu dot org
@ 2008-07-04 22:02 ` jsm28 at gcc dot gnu dot org
2009-03-30 21:45 ` jsm28 at gcc dot gnu dot org
13 siblings, 0 replies; 15+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2008-07-04 22:02 UTC (permalink / raw)
To: gcc-bugs
------- Comment #11 from jsm28 at gcc dot gnu dot org 2008-07-04 22:01 -------
Closing 4.1 branch.
--
jsm28 at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|[4.1/4.2 regression] ICE |[4.2 regression] ICE with
|with invalid redeclaration |invalid redeclaration of
|of builtin |builtin
Target Milestone|4.1.3 |4.2.5
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug c++/31749] [4.2 regression] ICE with invalid redeclaration of builtin
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
` (12 preceding siblings ...)
2008-07-04 22:02 ` [Bug c++/31749] [4.2 " jsm28 at gcc dot gnu dot org
@ 2009-03-30 21:45 ` jsm28 at gcc dot gnu dot org
13 siblings, 0 replies; 15+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2009-03-30 21:45 UTC (permalink / raw)
To: gcc-bugs
------- Comment #12 from jsm28 at gcc dot gnu dot org 2009-03-30 21:45 -------
Closing 4.2 branch, fixed in 4.3.
--
jsm28 at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |RESOLVED
Known to fail| |4.2.5
Known to work| |4.3.0
Resolution| |FIXED
Target Milestone|4.2.5 |4.3.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31749
^ permalink raw reply [flat|nested] 15+ messages in thread
end of thread, other threads:[~2009-03-30 21:45 UTC | newest]
Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-04-29 11:11 [Bug c++/31749] New: [4.1/4.2/4.3 regression] ICE with invalid redeclaration of builtin reichelt at gcc dot gnu dot org
2007-04-29 11:11 ` [Bug c++/31749] " reichelt at gcc dot gnu dot org
2007-04-30 18:54 ` mmitchel at gcc dot gnu dot org
2007-04-30 21:47 ` aaw at google dot com
2007-04-30 23:25 ` aaw at google dot com
2007-05-22 21:41 ` aaw at gcc dot gnu dot org
2007-08-06 15:13 ` pinskia at gcc dot gnu dot org
2007-08-06 21:24 ` aaw at gcc dot gnu dot org
2007-08-06 23:17 ` aaw at gcc dot gnu dot org
2007-08-07 19:15 ` patchapp at dberlin dot org
2007-08-17 21:43 ` aaw at gcc dot gnu dot org
2007-08-18 6:26 ` aaw at gcc dot gnu dot org
2007-08-18 9:07 ` [Bug c++/31749] [4.1/4.2 " pinskia at gcc dot gnu dot org
2008-07-04 22:02 ` [Bug c++/31749] [4.2 " jsm28 at gcc dot gnu dot org
2009-03-30 21:45 ` jsm28 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).