Chris Lattner | 4dcf151a | 2009-04-22 05:57:30 +0000 | [diff] [blame] | 1 | // Test this without pch. |
| 2 | // RUN: clang-cc -fblocks -include %S/objc_exprs.h -fsyntax-only -verify %s && |
| 3 | |
| 4 | // Test with pch. |
| 5 | // RUN: clang-cc -x objective-c-header -emit-pch -fblocks -o %t %S/objc_exprs.h && |
| 6 | // RUN: clang-cc -fblocks -include-pch %t -fsyntax-only -verify %s |
| 7 | |
Chris Lattner | 3a57a37 | 2009-04-22 06:29:42 +0000 | [diff] [blame^] | 8 | |
| 9 | |
| 10 | int *A1 = (objc_string)0; // expected-warning {{'struct objc_object *'}} |
| 11 | |
| 12 | char A2 = (objc_encode){}; // expected-error {{initializer element is not a compile-time constant}} \ |
| 13 | expected-warning {{char [2]}} |
| 14 | |
| 15 | int *A3 = (objc_protocol)0; // expected-warning {{aka 'Protocol *'}} |
| 16 | |
| 17 | |
| 18 | |