[swift-evolution] [Pitch] Replace the ternary operator with an in-language function

Mark Sands marksands07 at gmail.com
Wed Oct 26 11:55:01 CDT 2016


Training users to expect source-breaking churn would be highly damaging to
> the language. The removal of C-style for loops and increment/decrement
> operators came with sufficient justification beyond their being inherited
> from C. I don’t think there’s a sufficient justification for this change,
> especially with the bar set high for such changes.
>
> Preston
>

My apologies for skewing the conversation off-topic. I think what I meant
to imply is that we shouldn't be afraid of a deprecation warning. Migrating
away from a ternary operator is trivial, and the consequences usually come
with better readability.

Ignoring my statement about "leftovers from C" opposition, I *do* think
there is sufficient and very strong justification from the 10 items that
Charlotte has listed. I think it would be more valuable if one could pick
apart each bullet point they find excusable and list their reasons why it's
not compelling enough to warrant change.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20161026/1bc653cb/attachment.html>


More information about the swift-evolution mailing list