While the "native" one in IO doesn't take a PartialFunction:
def onError(f: Throwable => IO[Unit]): IO[A]
That could lead to some surprises if you would rewrite a piece of code from tagless final to IO, or if you are just used to using the onError extension method in other code.
The
onError
that you get fromApplicativeError
has this signature:While the "native" one in
IO
doesn't take aPartialFunction
:That could lead to some surprises if you would rewrite a piece of code from tagless final to
IO
, or if you are just used to using theonError
extension method in other code.