[swift-evolution] ternary operator ?: suggestion
clattner at apple.com
Tue Jan 19 19:12:41 CST 2016
> On Jan 19, 2016, at 3:17 PM, Thorsten Seitz <tseitz42 at icloud.com> wrote:
>>> The big advantage of the partial function proposal would be that it is much more general as it is usable everywhere a unary function argument is used, i.e. for map etc.
>> Sure, you’re optimizing for one specific case at the expense of composability. I personally don’t find that compelling, but YMMV.
> I’m not sure I understand. What specific case do you mean and what composability is lost with the unary function approach?
I’m saying that tying closure expressions and switch expressions together makes it inconvenient when you want a local switch in a non-function context.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the swift-evolution