comparison gcc/testsuite/gcc.dg/bitfld-13.c @ 111:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents
children
comparison
equal deleted inserted replaced
68:561a7518be6b 111:04ced10e8804
1 /* Test invalid bit-field types: bug 18498. */
2 /* { dg-do compile } */
3 /* { dg-options "" } */
4
5 int
6 main(void)
7 {
8 struct X {
9 int s[20] : 1; /* { dg-error "bit-field 's' has invalid type" } */
10 int *p : 2; /* { dg-error "bit-field 'p' has invalid type" } */
11 int (*f)(float) : 3; /* { dg-error "bit-field 'f' has invalid type" } */
12 } x;
13 return 0;
14 }