I don’t know the answer to your question, but I think that what is needed is just a bit of syntactic sugar, e.g. Rust has ? for returning compatible errors without looking into them. That seems to be powered by Try trait, that may be a monad, but I am not fluent enough to check if it formally is.
I don’t know the answer to your question, but I think that what is needed is just a bit of syntactic sugar, e.g. Rust has
?
for returning compatible errors without looking into them. That seems to be powered byTry
trait, that may be a monad, but I am not fluent enough to check if it formally is.