public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/51477] New: [c++0x] ICE with initialization of invalid non-static data member
@ 2011-12-08 23:46 reichelt at gcc dot gnu.org
2011-12-13 15:01 ` [Bug c++/51477] " dodji at gcc dot gnu.org
` (5 more replies)
0 siblings, 6 replies; 7+ messages in thread
From: reichelt at gcc dot gnu.org @ 2011-12-08 23:46 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51477
Bug #: 51477
Summary: [c++0x] ICE with initialization of invalid non-static
data member
Classification: Unclassified
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: reichelt@gcc.gnu.org
The following invalid code snippet triggers an ICE on trunk:
===========================
struct A
{
typedef int int T;
struct T x[1] = { 0 };
};
===========================
bug.cc:3:19: error: two or more data types in declaration of 'T'
bug.cc:1:8: internal compiler error: Segmentation fault
Please submit a full bug report, [etc.]
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/51477] [c++0x] ICE with initialization of invalid non-static data member
2011-12-08 23:46 [Bug c++/51477] New: [c++0x] ICE with initialization of invalid non-static data member reichelt at gcc dot gnu.org
@ 2011-12-13 15:01 ` dodji at gcc dot gnu.org
2011-12-13 21:55 ` dodji at gcc dot gnu.org
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: dodji at gcc dot gnu.org @ 2011-12-13 15:01 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51477
Dodji Seketeli <dodji at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |ASSIGNED
Last reconfirmed| |2011-12-13
CC| |dodji at gcc dot gnu.org
AssignedTo|unassigned at gcc dot |dodji at gcc dot gnu.org
|gnu.org |
Ever Confirmed|0 |1
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/51477] [c++0x] ICE with initialization of invalid non-static data member
2011-12-08 23:46 [Bug c++/51477] New: [c++0x] ICE with initialization of invalid non-static data member reichelt at gcc dot gnu.org
2011-12-13 15:01 ` [Bug c++/51477] " dodji at gcc dot gnu.org
@ 2011-12-13 21:55 ` dodji at gcc dot gnu.org
2011-12-13 22:52 ` dodji at gcc dot gnu.org
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: dodji at gcc dot gnu.org @ 2011-12-13 21:55 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51477
--- Comment #1 from Dodji Seketeli <dodji at gcc dot gnu.org> 2011-12-13 21:53:07 UTC ---
Candidate patch posted to
http://gcc.gnu.org/ml/gcc-patches/2011-12/msg01052.html
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/51477] [c++0x] ICE with initialization of invalid non-static data member
2011-12-08 23:46 [Bug c++/51477] New: [c++0x] ICE with initialization of invalid non-static data member reichelt at gcc dot gnu.org
2011-12-13 15:01 ` [Bug c++/51477] " dodji at gcc dot gnu.org
2011-12-13 21:55 ` dodji at gcc dot gnu.org
@ 2011-12-13 22:52 ` dodji at gcc dot gnu.org
2011-12-13 22:55 ` dodji at gcc dot gnu.org
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: dodji at gcc dot gnu.org @ 2011-12-13 22:52 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51477
--- Comment #2 from Dodji Seketeli <dodji at gcc dot gnu.org> 2011-12-13 22:50:55 UTC ---
I can't reproduce the behaviour on recent builds from trunk. E.g, on
r182308 I am getting:
$ cat -n test-PR51475.cc
1 #include <initializer_list>
2
3 struct A
4 {
5 A(int*);
6 };
7
8 struct B
9 {
10 const std::initializer_list<A>& x;
11 };
12
13 B b = {{1}};
$ ./cc1plus -quiet -std=c++11 -I ../../libstdc++-v3/libsupc++/
-I../x86_64-unknown-linux-gnu/libstdc++-v3/include/
-I../x86_64-unknown-linux-gnu/libstdc++-v3/include/x86_64-unknown-linux-gnu/
test-PR51477.cc
test-PR51477.cc:13:11: erreur: invalid conversion from ‘<brace-enclosed
initializer list>’ to ‘const std::initializer_list<A>&’ [-fpermissive]
test-PR51477.cc:13:11: erreur: cannot convert ‘{1}’ from type ‘<brace-enclosed
initializer list>’ to type ‘const std::initializer_list<A>&’
$
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/51477] [c++0x] ICE with initialization of invalid non-static data member
2011-12-08 23:46 [Bug c++/51477] New: [c++0x] ICE with initialization of invalid non-static data member reichelt at gcc dot gnu.org
` (2 preceding siblings ...)
2011-12-13 22:52 ` dodji at gcc dot gnu.org
@ 2011-12-13 22:55 ` dodji at gcc dot gnu.org
2011-12-19 9:48 ` dodji at gcc dot gnu.org
2011-12-19 10:11 ` dodji at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: dodji at gcc dot gnu.org @ 2011-12-13 22:55 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51477
--- Comment #3 from Dodji Seketeli <dodji at gcc dot gnu.org> 2011-12-13 22:52:13 UTC ---
Err, sorry the previous comment was for another bug. Forget about it.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/51477] [c++0x] ICE with initialization of invalid non-static data member
2011-12-08 23:46 [Bug c++/51477] New: [c++0x] ICE with initialization of invalid non-static data member reichelt at gcc dot gnu.org
` (3 preceding siblings ...)
2011-12-13 22:55 ` dodji at gcc dot gnu.org
@ 2011-12-19 9:48 ` dodji at gcc dot gnu.org
2011-12-19 10:11 ` dodji at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: dodji at gcc dot gnu.org @ 2011-12-19 9:48 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51477
--- Comment #4 from Dodji Seketeli <dodji at gcc dot gnu.org> 2011-12-19 09:47:51 UTC ---
Author: dodji
Date: Mon Dec 19 09:47:46 2011
New Revision: 182474
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=182474
Log:
PR c++/51477 - ICE with invalid NSDMI
gcc/cp/
PR c++/51477
* search.c (lookup_member): Get out early on invalid base type.
gcc/testsuite/
PR c++/51477
* g++.dg/cpp0x/nsdmi6.C: New test.
Added:
trunk/gcc/testsuite/g++.dg/cpp0x/nsdmi6.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/search.c
trunk/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/51477] [c++0x] ICE with initialization of invalid non-static data member
2011-12-08 23:46 [Bug c++/51477] New: [c++0x] ICE with initialization of invalid non-static data member reichelt at gcc dot gnu.org
` (4 preceding siblings ...)
2011-12-19 9:48 ` dodji at gcc dot gnu.org
@ 2011-12-19 10:11 ` dodji at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: dodji at gcc dot gnu.org @ 2011-12-19 10:11 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51477
Dodji Seketeli <dodji at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
--- Comment #5 from Dodji Seketeli <dodji at gcc dot gnu.org> 2011-12-19 09:48:32 UTC ---
This should be fixed in trunk (4.7)
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2011-12-19 9:48 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-12-08 23:46 [Bug c++/51477] New: [c++0x] ICE with initialization of invalid non-static data member reichelt at gcc dot gnu.org
2011-12-13 15:01 ` [Bug c++/51477] " dodji at gcc dot gnu.org
2011-12-13 21:55 ` dodji at gcc dot gnu.org
2011-12-13 22:52 ` dodji at gcc dot gnu.org
2011-12-13 22:55 ` dodji at gcc dot gnu.org
2011-12-19 9:48 ` dodji at gcc dot gnu.org
2011-12-19 10:11 ` dodji at gcc dot gnu.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).