> On Feb 23, 2017, at 12:52 PM, Anton Zhilin via swift-evolution 
> <[email protected]> wrote:
> 
> +1 to foo(:) version.
> I can easily see placeholder arguments as a sugary syntax for closures:
> 
This shorthand has been explicitly rejected several times in favor of the $ 
argument shorthand.

> func bar(_ x: Int, _ y: Double)
> let f = bar(_, 42)   // the same as:
> let f = { (x: Int) in bar(x, 42) }
> Now, let’s view a single-parameter version:
> 
> func foo(_ x: Int)
> let f = foo(_)   // the same as:
> let f = { (x: Int) in foo(x) }
> _______________________________________________
> swift-evolution mailing list
> [email protected]
> https://lists.swift.org/mailman/listinfo/swift-evolution

_______________________________________________
swift-evolution mailing list
[email protected]
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to