PR tree-optimization/86401
[official-gcc.git] / gcc / testsuite / c-c++-common / nonnull-3.c
blobd2ccb24f4fdb270401ac18ba42075f0cdd418b99
1 /* PR c++/79984 */
2 /* { dg-do compile } */
3 /* { dg-options "-Wnonnull-compare" } */
5 enum { r = 1 };
7 __attribute__ ((nonnull (r))) int
8 f (int *p)
10 return p == 0; /* { dg-warning "nonnull argument 'p' compared to NULL" } */