1 // { dg-options "-Wzero-as-null-pointer-constant" }
2 // { dg-do compile { target c++11 } }
3 
4 #include <cstddef>
5 
test01()6 void test01()
7 {
8   char* x(NULL);
9   char* x2{NULL};
10   char* x3 = NULL;
11   char* x4(0); // { dg-warning "12: zero as null pointer" }
12   char* x5 = 0; // { dg-warning "14: zero as null pointer" }
13 }
14