Daily bump.
[official-gcc.git] / gcc / testsuite / gcc.dg / c90-array-lval-8.c
blobbc5b7b21b8a559cccfae6149c99ef567729eca6f
1 /* Test for non-lvalue arrays: test that they cannot be assigned to
2 array variables. PR 58235. */
3 /* { dg-do compile } */
4 /* { dg-options "-std=iso9899:1990 -pedantic-errors" } */
6 struct s { char c[1]; } x;
7 struct s f (void) { return x; }
9 void
10 g (void)
12 char c[1];
13 c = f ().c; /* { dg-error "array" } */
16 void
17 h (void)
19 char c[1] = f ().c; /* { dg-error "array" } */