Debian Codegraph @

gcc/testsuite/g++.dg/ext/vla10.C

raw
1 // PR c++/48446
2 // { dg-options "" }
3
4 template<typename T>
5 struct A
6 {
7 ~A ();
8 T *operator-> () const;
9 };
10
11 struct B
12 {
13 typedef A <B> P;
14 static P foo (int);
15 };
16
17 struct C
18 {
19 typedef A<C> P;
20 static const int c = 80;
21 };
22
23 C::P bar ();
24
25 void
26 baz ()
27 {
28 char z[bar ()->c];
29 {
30 B::P m = B::foo (sizeof (z));
31 }
32 }