Mercurial > hg > CbC > CbC_gcc
annotate gcc/testsuite/g++.dg/cpp0x/constexpr-70001-2.C @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | 04ced10e8804 |
children |
rev | line source |
---|---|
111 | 1 // PR c++/70001 |
2 // { dg-do run { target c++11 } } | |
3 | |
4 struct B | |
5 { | |
6 struct B *a; | |
7 constexpr B () : a (this) { } | |
8 }; | |
9 | |
10 constexpr int N = 1 << 4; | |
11 struct A { B c[N]; } d; | |
12 | |
13 int | |
14 main () | |
15 { | |
16 for (int i = 0; i < N; ++i) | |
17 if (d.c[i].a != &d.c[i]) | |
18 __builtin_abort (); | |
19 } |