2014-12-15 11:48 GMT+01:00 Paolo Carlini :
> ... committed as obvious the below.
>
> Paolo.
>
> /
Thanks
Kai
... committed as obvious the below.
Paolo.
/
2014-12-15 Paolo Carlini
* g++.dg/cpp1y/pr63996.C: Fix.
Index: g++.dg/cpp1y/pr63996.C
===
--- g++.dg/cpp1y/pr63996.C (revision 218737)
+++ g++.dg/cpp1
Kai Tietz writes:
> New testcase in g++.dg/cpp1y as pr63996.C
>
> // { dg-do compile { target c++14 } }
>
> constexpr int
> foo (int i)
> {
> int a[i] = { };
> }
>
> constexpr int j = foo (1); // { dg-error "is not a constant expression" }
FAIL: g++.dg/cpp1y/pr63996.C -std=c++14 (test for exc
Hi,
On 12/12/2014 11:58 AM, Kai Tietz wrote:
New testcase in g++.dg/cpp1y as pr63996.C
// { dg-do compile { target c++14 } }
constexpr int
foo (int i)
{
int a[i] = { };
}
constexpr int j = foo (1); // { dg-error "is not a constant expression" }
The testcase fails spuriously because of Jaso
OK.
Jason
Hi,
The loop-expression loops endless in c++14's case for cases the
statement-list isn't constant.
Bug 63996 - Infinite loop in invalid C++14 constexpr fn
ChangeLog
2014-12-12 Kai Tietz
PR c++/63996
* constexpr.c (cxx_eval_loop_expr): Don't loop
endless on none-constant expressi