[swift-evolution] Adding Result to the Standard Library

Adrian Zubarev adrian.zubarev at devandartist.com
Fri Nov 3 06:16:47 CDT 2017


To be fair, I would want to see the outcome of the `typed throws` discussion first before moving the discussion about `Result` forward. 


Am 3. November 2017 um 04:41:32, Chris Lattner via swift-evolution (swift-evolution at swift.org) schrieb:


On Nov 2, 2017, at 11:08 AM, Jon Shier via swift-evolution <swift-evolution at swift.org> wrote:

Swift-Evolution:
I’ve written a first draft of a proposal to add Result<T> to the standard library by directly porting the Result<T> type used in Alamofire to the standard library. I’d be happy to implement it (type and tests for free!) if someone could point me to the right place to do so. I’m not including it directly in this email, since it includes the full implementation and is therefore quite long. (Discourse, please!) 

https://github.com/jshier/swift-evolution/blob/master/proposals/0187-add-result-to-the-standard-library.md

I’m generally supportive of this, but the design of such a thing forces another contentious issue: whether the error handling model should be extended to support "typed throws”.  Without result, we can carry on pushing the "typed throws” debate down the road.  Adding it would force that issue to be decided, which is complicated.

-Chris


_______________________________________________
swift-evolution mailing list
swift-evolution at swift.org
https://lists.swift.org/mailman/listinfo/swift-evolution
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20171103/fe1db023/attachment.html>


More information about the swift-evolution mailing list