https://wg21.link/P2505

On Tue, Oct 18, 2022 at 9:27 PM Shiroki Satsuki via Std-Proposals <std-proposals@lists.isocpp.org> wrote:
'std::expected' adds a nice way of handling errors without using the
exception system and will be included in C++ 23. 'std::optional' is
going to have monadic operations in this version too.

However, the current 'std::expected' proposal
(https://wg21.link/p0323r10) makes no mention of monadic operations,
neither 'transform' (aka 'map') nor 'and_then' (aka 'bind' or
'flatMap'). A generic associated types 'rebind<U>' is included, though.

It would be a pity if functional programming lovers must wait until C++
26 for a complete 'Either' monad.




--
Std-Proposals mailing list
Std-Proposals@lists.isocpp.org
https://lists.isocpp.org/mailman/listinfo.cgi/std-proposals


--
Regards,
Oleksandr Koval.