OSDN Git Service

PR c++/4222, c++/5995
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.old-deja / g++.other / null2.C
1 // Based on a testcase by Eric Dumazet <Eric.Dumazet@COSMOSBAY.COM>
2
3 extern "C" void abort ();
4
5 const char * const foo = ""; // foo is not NULL
6
7 int main() {
8   if ((foo == 0) ? 0 : foo)  // so this should evaluate to `foo'
9     return 0;
10   else
11     abort();
12 }