[swift-evolution] Making capturing semantics of local

Mike Kluev mike.kluev at gmail.com
Sat Oct 28 17:45:32 CDT 2017

on Date: Fri, 27 Oct 2017 15:15:15 -0400 Alex Lynch <lynch.sft at gmail.com>

I use local functions heavily in my day-to-day workflow and an very
> interested in them supporting capture lists.
> Here is a draft feature specification:
> https://bitbucket.org/snippets/lynchrb/r487zn
> Anyone see any weak spots?

this shall apply to methods as well, why not.

personally i'd put things like capture list (and even parameters/result in
case of closures) outside of the brackets.

> At present, the programer has no choice but to select a closure, even if
the use case would make a local function more expressive or easier to read.

this quote raises a general question: are closures harder to read and if so
can we do anything to improve their readability.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20171028/a0255d15/attachment.html>

More information about the swift-evolution mailing list