mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[AST] Preserve parameter names in TypeReprs of function types.
Also fixup 'test/SourceKit/CodeExpand/code-expand.swift' and use the syntax for adding parameter names with an underscore for first name.
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
// REQUIRES: se_0111_complete
|
||||
|
||||
// RUN: %sourcekitd-test -req=expand-placeholder %s | FileCheck %s
|
||||
|
||||
foo(x: <#T##() -> Void#>)
|
||||
@@ -17,7 +15,7 @@ anArr.indexOfObjectPassingTest(<#T##predicate: ((AnyObject!, Int, UnsafePointer<
|
||||
// CHECK-NEXT: <#code#>
|
||||
// CHECK-NEXT: }
|
||||
|
||||
anArr.indexOfObjectPassingTest(<#T##predicate: ((obj: AnyObject!, idx: Int, stop: UnsafePointer<ObjCBool>) -> Bool)?##((obj: AnyObject!, idx: Int, stop: UnsafePointer<ObjCBool>) -> Bool)?#>)
|
||||
anArr.indexOfObjectPassingTest(<#T##predicate: ((_ obj: AnyObject!, _ idx: Int, _ stop: UnsafePointer<ObjCBool>) -> Bool)?##((_ obj: AnyObject!, _ idx: Int, _ stop: UnsafePointer<ObjCBool>) -> Bool)?#>)
|
||||
// CHECK: anArr.indexOfObjectPassingTest { (obj, idx, stop) -> Bool in
|
||||
// CHECK-NEXT: <#code#>
|
||||
// CHECK-NEXT: }
|
||||
|
||||
Reference in New Issue
Block a user