1f08c3bdfSopenharmony_cistruct a {
2f08c3bdfSopenharmony_ci	int  a:31;
3f08c3bdfSopenharmony_ci	int  b:32;
4f08c3bdfSopenharmony_ci	long c:63;
5f08c3bdfSopenharmony_ci	long d:64;
6f08c3bdfSopenharmony_ci	int  x:33;		// KO
7f08c3bdfSopenharmony_ci	long y:65;		// KO
8f08c3bdfSopenharmony_ci};
9f08c3bdfSopenharmony_cistatic struct a a;
10f08c3bdfSopenharmony_ci
11f08c3bdfSopenharmony_cistruct b {
12f08c3bdfSopenharmony_ci	int m1:-1;		// KO
13f08c3bdfSopenharmony_ci	int x1:2147483648;	// KO
14f08c3bdfSopenharmony_ci	int :0;
15f08c3bdfSopenharmony_ci	int a0:0;		// KO
16f08c3bdfSopenharmony_ci};
17f08c3bdfSopenharmony_cistatic struct b b;
18f08c3bdfSopenharmony_ci
19f08c3bdfSopenharmony_ci/*
20f08c3bdfSopenharmony_ci * check-name: bitfield-sizes
21f08c3bdfSopenharmony_ci * check-command: sparse -m64 $file
22f08c3bdfSopenharmony_ci *
23f08c3bdfSopenharmony_ci * check-error-start
24f08c3bdfSopenharmony_cibitfield-sizes.c:12:18: error: bitfield 'm1' has invalid width (-1)
25f08c3bdfSopenharmony_cibitfield-sizes.c:13:26: error: bitfield 'x1' has invalid width (2147483648)
26f08c3bdfSopenharmony_cibitfield-sizes.c:15:17: error: bitfield 'a0' has invalid width (0)
27f08c3bdfSopenharmony_cibitfield-sizes.c:6:15: error: bitfield 'x' is wider (33) than its type (int)
28f08c3bdfSopenharmony_cibitfield-sizes.c:7:15: error: bitfield 'y' is wider (65) than its type (long)
29f08c3bdfSopenharmony_ci * check-error-end
30f08c3bdfSopenharmony_ci */
31