Debian Codegraph @

gcc/testsuite/gcc.dg/Wpointer-to-int-cast-2.c

raw
1 /* Test -Wpointer-to-int-cast. */
2 /* Origin: Joseph Myers <[email protected]> */
3 /* { dg-do compile } */
4 /* { dg-options "-Wpointer-to-int-cast" } */
5
6 void *p;
7
8 char
9 f (void)
10 {
11 return (char) p; /* { dg-warning "cast from pointer to integer of different size" } */
12 }