[Bug c++/51633] [c++0x] [4.6/4.7 Regression] ICE with invalid constexpr constructor

dodji at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Thu Jan 12 23:30:00 GMT 2012


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

--- Comment #6 from Dodji Seketeli <dodji at gcc dot gnu.org> 2012-01-12 23:28:52 UTC ---
Author: dodji
Date: Thu Jan 12 23:28:46 2012
New Revision: 183144

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=183144
Log:
PR c++/51633 - ICEs with constexpr constructor

gcc/cp/

    PR c++/51633
    * semantics.c (cp_parser_ctor_initializer_opt_and_function_body):
    Set the pointer to the last block of the constructor to the
    current statement.
    (build_constexpr_constructor_member_initializers): Get
    build_data_member_initialization a chance to deal with more
    statements before we choke.

gcc/testsuite/

    PR c++/51633
    * g++.dg/cpp0x/constexpr-diag4.C: New test.

Added:
    trunk/gcc/testsuite/g++.dg/cpp0x/constexpr-diag4.C
    trunk/gcc/testsuite/g++.dg/cpp0x/constexpr-diag5.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/parser.c
    trunk/gcc/cp/semantics.c
    trunk/gcc/testsuite/ChangeLog



More information about the Gcc-bugs mailing list