blob: 796d7e0a9ae8e8eb753f15ad436ce26e4ec7e8bb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
/* PR c/35440 */
/* { dg-do compile } */
/* { dg-options "-std=gnu99" } */
struct A {};
struct B { int i; char j[2]; };
void foo (void)
{
(struct A){}(); /* { dg-error "called object" } */
(struct B){ .i = 2, .j[1] = 1 }(); /* { dg-error "called object" } */
}
|