Builder.AddTextChunk("sender");
Results.AddResult(CodeCompletionResult(Builder.TakeString()));
}
+
+ // If we're completing the return type, provide 'instancetype'.
+ if (!IsParameter) {
+ Results.AddResult(CodeCompletionResult("instancetype"));
+ }
// Add various builtin type names and specifiers.
AddOrdinaryNameResults(PCC_Type, S, *this, Results);
}
@end
+// RUN: c-index-test -code-completion-at=%s:7:4 %s | FileCheck -check-prefix=CHECK-CC0 %s
+// CHECK-CC0: NotImplemented:{TypedText IBAction}{RightParen )}{Placeholder selector}{Colon :}{LeftParen (}{Text id}{RightParen )}{Text sender} (40)
+// CHECK-CC0: macro definition:{TypedText IBAction} (70)
+// CHECK-CC0: macro definition:{TypedText IBOutlet} (70)
+// CHECK-CC0: macro definition:{TypedText IBOutletCollection}{LeftParen (}{Placeholder ClassName}{RightParen )} (70)
+// CHECK-CC0: TypedefDecl:{TypedText id} (50)
+// CHECK-CC0: NotImplemented:{TypedText in} (40)
+// CHECK-CC0: NotImplemented:{TypedText inout} (40)
+// CHECK-CC0: NotImplemented:{TypedText instancetype} (40)
+// CHECK-CC0: NotImplemented:{TypedText int} (50)
+// CHECK-CC0: NotImplemented:{TypedText long} (50)
// RUN: c-index-test -code-completion-at=%s:7:19 %s | FileCheck -check-prefix=CHECK-CC1 %s
// CHECK-CC1-NOT: NotImplemented:{TypedText extern} (40)
// CHECK-CC1: NotImplemented:{TypedText param1} (40)