$ cat foo.c
#include <limits.h>
int main() {
int x = INT_MAX+1;
*(int *)0;
}
$ clang foo.c
foo.c:3:17: warning: overflow in expression; result is -2147483648 with type 'int' [-Winteger-overflow]
int x = INT_MAX+1;
^
foo.c:4:2: warning: indirection of non-volatile null pointer will be deleted, not trap [-Wnull-dereference]
*(int *)0;
^~~~~~~~~
foo.c:4:2: note: consider using __builtin_trap() or qualifying pointer with 'volatile'
3 warnings generated.