public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/52905] New: [C++0x] ice on invalid brace-enclosed initializer of vector of enums
@ 2012-04-08 15:50 dirkmoermans at gmail dot com
  2012-04-08 16:18 ` [Bug c++/52905] " dirkmoermans at gmail dot com
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: dirkmoermans at gmail dot com @ 2012-04-08 15:50 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52905

             Bug #: 52905
           Summary: [C++0x] ice on invalid brace-enclosed initializer of
                    vector of enums
    Classification: Unclassified
           Product: gcc
           Version: 4.6.1
            Status: UNCONFIRMED
          Severity: minor
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: dirkmoermans@gmail.com


The invalid code below ICEs on gcc 4.6.1 and gcc 4.7.0.

It is caused by passing an int as an initializer to a vector of enums.

===
#include <vector>

enum ev {a,b,c};
std::vector<ev> v{a,-1}; // ICE
// std::vector<ev> v{a,b}; // passes
===

The messages are:

internal compiler error: in joust, at cp/call.c:7642 (g++-4.6.1)

internal compiler error: in joust, at cp/call.c:8009 (g++-4.7)


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug c++/52905] [C++0x] ice on invalid brace-enclosed initializer of vector of enums
  2012-04-08 15:50 [Bug c++/52905] New: [C++0x] ice on invalid brace-enclosed initializer of vector of enums dirkmoermans at gmail dot com
@ 2012-04-08 16:18 ` dirkmoermans at gmail dot com
  2012-04-08 18:02 ` redi at gcc dot gnu.org
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: dirkmoermans at gmail dot com @ 2012-04-08 16:18 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52905

--- Comment #1 from Dirk Moermans <dirkmoermans at gmail dot com> 2012-04-08 16:17:40 UTC ---
I compile with g++ -std=c++0x


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug c++/52905] [C++0x] ice on invalid brace-enclosed initializer of vector of enums
  2012-04-08 15:50 [Bug c++/52905] New: [C++0x] ice on invalid brace-enclosed initializer of vector of enums dirkmoermans at gmail dot com
  2012-04-08 16:18 ` [Bug c++/52905] " dirkmoermans at gmail dot com
@ 2012-04-08 18:02 ` redi at gcc dot gnu.org
  2012-04-13 17:03 ` jason at gcc dot gnu.org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: redi at gcc dot gnu.org @ 2012-04-08 18:02 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52905

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice-on-invalid-code
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2012-04-08
     Ever Confirmed|0                           |1

--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-04-08 18:02:07 UTC ---
confirmed


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug c++/52905] [C++0x] ice on invalid brace-enclosed initializer of vector of enums
  2012-04-08 15:50 [Bug c++/52905] New: [C++0x] ice on invalid brace-enclosed initializer of vector of enums dirkmoermans at gmail dot com
  2012-04-08 16:18 ` [Bug c++/52905] " dirkmoermans at gmail dot com
  2012-04-08 18:02 ` redi at gcc dot gnu.org
@ 2012-04-13 17:03 ` jason at gcc dot gnu.org
  2012-04-13 19:44 ` jason at gcc dot gnu.org
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2012-04-13 17:03 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52905

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
                 CC|                            |jason at gcc dot gnu.org
         AssignedTo|unassigned at gcc dot       |jason at gcc dot gnu.org
                   |gnu.org                     |


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug c++/52905] [C++0x] ice on invalid brace-enclosed initializer of vector of enums
  2012-04-08 15:50 [Bug c++/52905] New: [C++0x] ice on invalid brace-enclosed initializer of vector of enums dirkmoermans at gmail dot com
                   ` (2 preceding siblings ...)
  2012-04-13 17:03 ` jason at gcc dot gnu.org
@ 2012-04-13 19:44 ` jason at gcc dot gnu.org
  2012-04-13 19:52 ` jason at gcc dot gnu.org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2012-04-13 19:44 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52905

--- Comment #3 from Jason Merrill <jason at gcc dot gnu.org> 2012-04-13 19:43:52 UTC ---
Author: jason
Date: Fri Apr 13 19:43:47 2012
New Revision: 186433

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=186433
Log:
    PR c++/52905
    * call.c (joust): Handle comparing list and non-list ctors.

Added:
    trunk/gcc/testsuite/g++.dg/cpp0x/initlist-ctor1.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/call.c
    trunk/gcc/testsuite/ChangeLog


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug c++/52905] [C++0x] ice on invalid brace-enclosed initializer of vector of enums
  2012-04-08 15:50 [Bug c++/52905] New: [C++0x] ice on invalid brace-enclosed initializer of vector of enums dirkmoermans at gmail dot com
                   ` (3 preceding siblings ...)
  2012-04-13 19:44 ` jason at gcc dot gnu.org
@ 2012-04-13 19:52 ` jason at gcc dot gnu.org
  2012-05-31 14:29 ` jason at gcc dot gnu.org
  2012-05-31 14:39 ` jason at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2012-04-13 19:52 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52905

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|---                         |4.8.0

--- Comment #4 from Jason Merrill <jason at gcc dot gnu.org> 2012-04-13 19:52:31 UTC ---
Fixed for 4.8.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug c++/52905] [C++0x] ice on invalid brace-enclosed initializer of vector of enums
  2012-04-08 15:50 [Bug c++/52905] New: [C++0x] ice on invalid brace-enclosed initializer of vector of enums dirkmoermans at gmail dot com
                   ` (4 preceding siblings ...)
  2012-04-13 19:52 ` jason at gcc dot gnu.org
@ 2012-05-31 14:29 ` jason at gcc dot gnu.org
  2012-05-31 14:39 ` jason at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2012-05-31 14:29 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52905

--- Comment #5 from Jason Merrill <jason at gcc dot gnu.org> 2012-05-31 14:28:46 UTC ---
Author: jason
Date: Thu May 31 14:28:41 2012
New Revision: 188063

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=188063
Log:
    PR c++/53500
    PR c++/52905
    * call.c (joust): Handle comparing list and non-list ctors.

Added:
    branches/gcc-4_7-branch/gcc/testsuite/g++.dg/cpp0x/initlist-ctor1.C
Modified:
    branches/gcc-4_7-branch/gcc/cp/ChangeLog
    branches/gcc-4_7-branch/gcc/cp/call.c
    branches/gcc-4_7-branch/gcc/testsuite/ChangeLog


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug c++/52905] [C++0x] ice on invalid brace-enclosed initializer of vector of enums
  2012-04-08 15:50 [Bug c++/52905] New: [C++0x] ice on invalid brace-enclosed initializer of vector of enums dirkmoermans at gmail dot com
                   ` (5 preceding siblings ...)
  2012-05-31 14:29 ` jason at gcc dot gnu.org
@ 2012-05-31 14:39 ` jason at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: jason at gcc dot gnu.org @ 2012-05-31 14:39 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52905

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.8.0                       |4.7.1

--- Comment #5 from Jason Merrill <jason at gcc dot gnu.org> 2012-05-31 14:28:46 UTC ---
Author: jason
Date: Thu May 31 14:28:41 2012
New Revision: 188063

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=188063
Log:
    PR c++/53500
    PR c++/52905
    * call.c (joust): Handle comparing list and non-list ctors.

Added:
    branches/gcc-4_7-branch/gcc/testsuite/g++.dg/cpp0x/initlist-ctor1.C
Modified:
    branches/gcc-4_7-branch/gcc/cp/ChangeLog
    branches/gcc-4_7-branch/gcc/cp/call.c
    branches/gcc-4_7-branch/gcc/testsuite/ChangeLog


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2012-05-31 14:32 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-04-08 15:50 [Bug c++/52905] New: [C++0x] ice on invalid brace-enclosed initializer of vector of enums dirkmoermans at gmail dot com
2012-04-08 16:18 ` [Bug c++/52905] " dirkmoermans at gmail dot com
2012-04-08 18:02 ` redi at gcc dot gnu.org
2012-04-13 17:03 ` jason at gcc dot gnu.org
2012-04-13 19:44 ` jason at gcc dot gnu.org
2012-04-13 19:52 ` jason at gcc dot gnu.org
2012-05-31 14:29 ` jason at gcc dot gnu.org
2012-05-31 14:39 ` jason 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).