[swift-evolution] Add an ifPresent function to Optional

davesweeris at mac.com davesweeris at mac.com
Mon Mar 14 20:54:00 CDT 2016


> On Mar 14, 2016, at 8:29 PM, Dmitri Gribenko <gribozavr at gmail.com> wrote:
> 
> As a standard library engineer I can with certainty that this is not
> the plan.  We like the current formulation of map() that returns an
> Array.
Oh, well that settles that, then. Plus, now I feel kinda silly trying to explain it to you. :-)

> https://github.com/apple/swift/blob/master/docs/StdlibRationales.rst#high-order-functions-on-collections-return-arrays
Cool! I’d missed that, thanks!

- Dave Sweeris


More information about the swift-evolution mailing list