]>
git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/testsuite/gcc.dg/Warray-bounds-42.c
1 /* PR tree-optimization/89720 - Spurious -Warray-bounds warning on a range
4 { dg-options "-O2 -Wall" } */
8 #if __SIZEOF_POINTER__ == 8
10 void g (__INT64_TYPE__ i
)
13 char *p
= a
+ (i
& (__INT64_TYPE__
)0xffffffff3fffffffLL
);
14 f (p
, *(p
- 6)); /* { dg-bogus "\\\[-Warray-bounds" } */
17 #elif __SIZEOF_POINTER__ == 4
19 void h (__INT32_TYPE__ i
)
22 char *p
= a
+ (i
& (__INT32_TYPE__
)0x8fffffffLL
);
23 f (p
, *(p
- 6)); /* { dg-bogus "\\\[-Warray-bounds" } */