[swift-evolution] [pitch] Eliminate the "T1 -> T2" syntax, require "(T1) -> T2"
davesweeris at mac.com
davesweeris at mac.com
Sat Apr 16 14:25:24 CDT 2016
> On Apr 16, 2016, at 12:10 PM, Patrick Gili via swift-evolution <swift-evolution at swift.org> wrote:
>
> As an alternative, could we require the parens on the return. For example:
>
> (Int) -> (Float)
> (String) -> ()
> () -> ()
> () -> (Double)
>
> This looks cleaner, improves consistency, and simplifies the syntax (i.e., no need to remember when parens are necessary).
>
> -Patrick
I’m not sure it’s “cleaner” per se, but I agree with the rest. My earlier +1 may have been premature…
- Dave Sweeris
More information about the swift-evolution
mailing list