| 1 |
// { dg-do run } |
| 2 |
// g++ bug 900406_02 |
| 3 |
|
| 4 |
// g++ fails to correctly parse some type specifications within casts. |
| 5 |
|
| 6 |
// This results in incorrect errors being issued. |
| 7 |
|
| 8 |
// These errors are not issued for identical code by either cfront or |
| 9 |
// by gcc. |
| 10 |
|
| 11 |
// cfront 2.0 passes this test. |
| 12 |
|
| 13 |
// keywords: syntax, array types, casts |
| 14 |
|
| 15 |
int (*ipp)[]; |
| 16 |
int (**ippp)[]; |
| 17 |
|
| 18 |
int function () |
| 19 |
{ |
| 20 |
ipp = (int (*)[]) 0; // OK |
| 21 |
ippp = (int (**)[]) 0; // { dg-bogus "" } (syntax) |
| 22 |
return 0; |
| 23 |
} |
| 24 |
|
| 25 |
int main () { return 0; } |
| 26 |
|