1// REQUIRES: x86-registered-target
2// RUN: %clang_cc1 -triple x86_64-apple-darwin10 -S %s -o - | FileCheck %s
3
4// rdar://9072317
5
6/** The problem looks like clang getting confused when a single translation unit
7    contains a protocol with a property and two classes that implement that protocol
8    and synthesize the property.
9*/
10
11@protocol Proto
12@property (assign) id prop;
13@end
14
15@interface NSObject @end
16
17@interface Foo : NSObject <Proto> { int x; } @end
18
19@interface Bar : NSObject <Proto> @end
20
21@implementation Foo
22@synthesize prop;
23@end
24
25@implementation Bar
26@synthesize prop;
27@end
28
29// CHECK: _OBJC_$_INSTANCE_METHODS_Bar:
30// CHECK-NEXT:        .long   24
31// CHECK-NEXT:        .long   2
32// CHECK-NEXT:        .quad   L_OBJC_METH_VAR_NAME_
33// CHECK-NEXT:        .quad   L_OBJC_METH_VAR_TYPE_
34// CHECK-NEXT:        .quad   "-[Bar prop]"
35