]> granicus.if.org Git - clang/commitdiff
Fix test case and add a FIXME.
authorSteve Naroff <snaroff@apple.com>
Wed, 30 Jan 2008 21:50:43 +0000 (21:50 +0000)
committerSteve Naroff <snaroff@apple.com>
Wed, 30 Jan 2008 21:50:43 +0000 (21:50 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@46577 91177308-0d34-0410-b5e6-96231b3b80d8

test/Sema/conditional-expr.c

index c7c6ff242c76a35f18e97e94b3fa42690c069e54..a113adeeb3870b67796ddba6224b096d4ed34f2a 100644 (file)
@@ -1,9 +1,10 @@
 // RUN: clang -fsyntax-only -verify -pedantic %s
 void foo() {
   *(0 ? (double *)0 : (void *)0) = 0;
+  // FIXME: GCC doesn't consider the the following two statements to be errors.
   *(0 ? (double *)0 : (void *)(int *)0) = 0; // expected-error {{incomplete type 'void' is not assignable}}
   *(0 ? (double *)0 : (void *)(double *)0) = 0; // expected-error {{incomplete type 'void' is not assignable}}
-  *(0 ? (double *)0 : (int *)(void *)0) = 0; // expected-warning {{pointer type mismatch ('double *' and 'int *')}}
+  *(0 ? (double *)0 : (int *)(void *)0) = 0; // expected-error {{incomplete type 'void' is not assignable}} expected-warning {{pointer type mismatch ('double *' and 'int *')}}
   *(0 ? (double *)0 : (double *)(void *)0) = 0;
   *((void *) 0) = 0; // expected-error {{incomplete type 'void' is not assignable}}
   double *dp;