[Bug c++/69516] [5/6 regression] infinite recursion on a VLA with excess initializer elements in constexpr function

2016-01-29 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69516

--- Comment #3 from Marek Polacek  ---
Author: mpolacek
Date: Fri Jan 29 09:25:14 2016
New Revision: 232969

URL: https://gcc.gnu.org/viewcvs?rev=232969=gcc=rev
Log:
PR c++/69509
PR c++/69516
* constexpr.c (cxx_eval_array_reference): Give the "array subscript
out of bound" error earlier.
* init.c (build_vec_init): Change NE_EXPR into GT_EXPR.  Update the
commentary.

* g++.dg/ext/constexpr-vla2.C: New test.
* g++.dg/ext/constexpr-vla3.C: New test.
* g++.dg/ubsan/vla-1.C: Remove dg-shouldfail.

Added:
trunk/gcc/testsuite/g++.dg/ext/constexpr-vla2.C
trunk/gcc/testsuite/g++.dg/ext/constexpr-vla3.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/constexpr.c
trunk/gcc/cp/init.c
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/g++.dg/ubsan/vla-1.C

[Bug c++/69516] [5/6 regression] infinite recursion on a VLA with excess initializer elements in constexpr function

2016-01-29 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69516

Marek Polacek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #4 from Marek Polacek  ---
Fixed for GCC 6.

[Bug c++/69516] [5/6 regression] infinite recursion on a VLA with excess initializer elements in constexpr function

2016-01-28 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69516

Richard Biener  changed:

   What|Removed |Added

   Target Milestone|--- |5.4

[Bug c++/69516] [5/6 regression] infinite recursion on a VLA with excess initializer elements in constexpr function

2016-01-28 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69516

Marek Polacek  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
   Assignee|unassigned at gcc dot gnu.org  |mpolacek at gcc dot 
gnu.org

--- Comment #2 from Marek Polacek  ---
Examining.

[Bug c++/69516] [5/6 regression] infinite recursion on a VLA with excess initializer elements in constexpr function

2016-01-27 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69516

Marek Polacek  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2016-01-27
 CC||mpolacek at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #1 from Marek Polacek  ---
Confirmed.