10 ms·
I would argue that `then` is better thought of as: Promise A E -> (A -> Promise A') -> (E -> Promise E') -> Promise A' E' , with implicit boxing of bare types
by acjohnson55 12y ago
I would argue that `then` is better thought of as:
Promise A E -> (A -> Promise A') -> (E -> Promise E') -> Promise A' E'
, with implicit boxing of bare types and thrown exceptions, as well as flattening of superfluous Promise wrappers. The `flatMap`iness of it is what really makes it interesting, in my opinion.