diff options
Diffstat (limited to 'test/Index/complete-properties.m')
-rw-r--r-- | test/Index/complete-properties.m | 27 |
1 files changed, 25 insertions, 2 deletions
diff --git a/test/Index/complete-properties.m b/test/Index/complete-properties.m index 725f180f7c29..ce1870e6511b 100644 --- a/test/Index/complete-properties.m +++ b/test/Index/complete-properties.m @@ -29,6 +29,22 @@ id test(I3 *i3) { return i3.Prop3; } +@interface I4 +@property id Prop2; +@end + +@interface I4 () { + I4 *Prop1; +} +@end + +@implementation I4 { + id Prop2_; +} + +@synthesize Prop2 = Prop2_; +@end + // RUN: c-index-test -code-completion-at=%s:20:13 %s | FileCheck -check-prefix=CHECK-CC1 %s // CHECK-CC1: ObjCPropertyDecl:{ResultType int}{TypedText Prop0} // CHECK-CC1: ObjCPropertyDecl:{ResultType int}{TypedText Prop1} @@ -41,8 +57,10 @@ id test(I3 *i3) { // CHECK-CC2-NEXT: ObjCPropertyDecl:{ResultType id}{TypedText Prop3} // CHECK-CC2: ObjCPropertyDecl:{ResultType id}{TypedText Prop4} // RUN: c-index-test -code-completion-at=%s:20:35 %s | FileCheck -check-prefix=CHECK-CC3 %s -// CHECK-CC3: ObjCIvarDecl:{ResultType int}{TypedText RandomIVar} -// CHECK-CC3: ObjCIvarDecl:{ResultType id}{TypedText StoredProp3} +// CHECK-CC3: ObjCIvarDecl:{ResultType id}{TypedText _Prop3} (36) +// CHECK-CC3: ObjCIvarDecl:{ResultType int}{TypedText RandomIVar} (35) +// CHECK-CC3: ObjCIvarDecl:{ResultType id}{TypedText StoredProp3} (8) + // RUN: c-index-test -code-completion-at=%s:21:10 %s | FileCheck -check-prefix=CHECK-CC4 %s // CHECK-CC4: ObjCPropertyDecl:{ResultType int}{TypedText Prop0} // CHECK-CC4-NEXT: ObjCPropertyDecl:{ResultType id}{TypedText Prop4} @@ -57,3 +75,8 @@ id test(I3 *i3) { // RUN: c-index-test -code-completion-at=%s:9:11 %s | FileCheck -check-prefix=CHECK-CC6 %s // CHECK-CC6: ObjCInterfaceDecl:{TypedText MyClass} (50) + +// RUN: c-index-test -code-completion-at=%s:45:21 -fobjc-nonfragile-abi %s | FileCheck -check-prefix=CHECK-CC7 %s +// CHECK-CC7-NOT: ObjCIvarDecl:{ResultType id}{TypedText _Prop2} +// CHECK-CC7: ObjCIvarDecl:{ResultType I4 *}{TypedText Prop1} (17) +// CHECK-CC7: ObjCIvarDecl:{ResultType id}{TypedText Prop2_} (7) |