Mercurial > hg > CbC > CbC_gcc
annotate gcc/testsuite/g++.dg/overload/VLA.C @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children |
rev | line source |
---|---|
111 | 1 //Origin: kengole@us.ibm.com |
2 | |
3 //PR c++/2478 | |
4 // G++ was rejecting this as it could not convert `int (*)[]' to `int (*)[0]'. | |
5 // Using the C99 VLA style arrays in a struct. | |
6 | |
7 // { dg-do compile } | |
8 | |
9 struct S { | |
10 int (*p)[]; | |
11 } B; | |
12 | |
13 void foo() { | |
14 int (*p)[]; | |
15 B.p=p; // { dg-bogus "cannot convert" } | |
16 } |