The return type of Result.matchBad for result T and handler map M:
the union of the handlers' return types. matchBad requires T to be a
Bad, so the result never includes undefined — an unhandled reason
throws instead.
Type Parameters
T
The Bad union being matched (kept for signature symmetry).
The return type of Result.matchBad for result
Tand handler mapM: the union of the handlers' return types.matchBadrequiresTto be a Bad, so the result never includesundefined— an unhandled reason throws instead.