[swift-evolution] What about renaming Optional.map to Optional.mapMe ?

David Sweeris davesweeris at mac.com
Mon Dec 5 23:17:59 CST 2016


> On Dec 5, 2016, at 8:54 PM, Jay Zhao <zhaojianyin at icloud.com> wrote:
> 
> What about mapUnwrapped ?

If the name is anything other than “map”, you already have to think of the “special” word. At that point, why not just unwrap it manually?
_ = array2?.count
vs
_ = array2?.map {$0.count}

I think this topic was discussed on the list a while ago… I’d have to go back, find the thread and reread it, since the same arguments would just come up again.

- Dave Sweeris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20161205/9954e16b/attachment.html>


More information about the swift-evolution mailing list