expectations 0.1.0
Paul Backus
snarwin at gmail.com
Mon Sep 3 00:38:43 UTC 2018
On Sunday, 2 September 2018 at 23:38:41 UTC, Per Nordlöw wrote:
> On Sunday, 2 September 2018 at 06:59:20 UTC, Paul Backus wrote:
>> expectations is an error-handling library that lets you bundle
>> exceptions together with return values. It is based on Rust's
>> Result<T, E> [1] and C++'s proposed std::expected. [2] If
>> you're not familiar with those, Andrei's NDC Oslo talk,
>> "Expect the Expected" [3], explains the advantages of this
>> approach to error handling in considerable detail.
>
> Incidentally, I've already proposed `Expected` into Phobos
> std.experimental.typecons here
>
> https://github.com/dlang/phobos/pull/6686
>
> Is it ok if I try to merge your effort into this pull request?
I don't think expectations has reached a high enough level of
quality yet to be ready for inclusion in Phobos. However, if
you'd like to submit it for comments as a WIP, or use it as a
reference for your own implementation, that's completely fine,
and I'd be happy to help you.
More information about the Digitalmars-d-announce
mailing list