TartanLlama / expected

C++11/14/17 std::expected with functional-style extensions

Home Page:https://tl.tartanllama.xyz

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

propagation of unexpected

reder2000 opened this issue · comments

commented

in a chain of function of functions returning expected<T,E> with different Ts but the same E, in would be handy to have the possibility to return the unexpected
return my_failed_expected.unexpected()
rather than writing
return tl::make_unexpected(my_failed_excepted.error())