Daniel Dunbar | a572887 | 2009-12-15 20:14:24 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 %s -verify -fms-extensions |
Steve Naroff | 0326e04 | 2008-06-03 13:21:30 +0000 | [diff] [blame] | 2 | @class NSInvocation, NSMethodSignature, NSCoder, NSString, NSEnumerator; |
| 3 | typedef struct _NSRange { } NSRange; |
| 4 | |
| 5 | @class PBXFileReference; |
| 6 | |
| 7 | @interface PBXDocBookmark |
Fariborz Jahanian | 8822f7c | 2010-03-27 19:02:17 +0000 | [diff] [blame] | 8 | + alloc; // expected-note {{{{method definition for 'alloc' not found}} |
| 9 | - autorelease; // expected-note {{{{method definition for 'autorelease' not found}} |
Steve Naroff | 0326e04 | 2008-06-03 13:21:30 +0000 | [diff] [blame] | 10 | @end |
Steve Naroff | a2ac06e | 2008-06-03 17:15:29 +0000 | [diff] [blame] | 11 | |
| 12 | // GCC allows pointer expressions in integer constant expressions. |
| 13 | struct { |
| 14 | char control[((int)(char *)2)]; |
| 15 | } xx; |
| 16 | |
Fariborz Jahanian | 8822f7c | 2010-03-27 19:02:17 +0000 | [diff] [blame] | 17 | @implementation PBXDocBookmark // expected-warning {{incomplete implementation}} |
Steve Naroff | 0326e04 | 2008-06-03 13:21:30 +0000 | [diff] [blame] | 18 | |
| 19 | + (id)bookmarkWithFileReference:(PBXFileReference *)fileRef gylphRange:(NSRange)range anchor:(NSString *)htmlAnchor |
| 20 | { |
| 21 | NSRange r = (NSRange)range; |
| 22 | return [[[self alloc] initWithFileReference:fileRef gylphRange:(NSRange)range anchor:(NSString *)htmlAnchor] autorelease]; // expected-warning {{method '-initWithFileReference:gylphRange:anchor:' not found (return type defaults to 'id')}} |
| 23 | } |
| 24 | @end |