From f00b9cd11641d4a1983e7a689f85d89270e2b92d Mon Sep 17 00:00:00 2001 From: Thanh Le Date: Sun, 8 Sep 2024 14:48:55 +0200 Subject: [PATCH] Revert implicit for Resource MonadError instance MonadCancelThrow instance (which is required for the fixed attempt) is already higher priority than this one. By leaving it implicit, users will get an actionable deprecation instead of non-compiling code. --- kernel/shared/src/main/scala/cats/effect/kernel/Resource.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/shared/src/main/scala/cats/effect/kernel/Resource.scala b/kernel/shared/src/main/scala/cats/effect/kernel/Resource.scala index 2f3d8f8cf1..942ca23e2d 100644 --- a/kernel/shared/src/main/scala/cats/effect/kernel/Resource.scala +++ b/kernel/shared/src/main/scala/cats/effect/kernel/Resource.scala @@ -1303,7 +1303,7 @@ private[effect] trait ResourceHOInstances3 extends ResourceHOInstances4 { private[effect] trait ResourceHOInstances4 extends ResourceHOInstances5 { @deprecated("Use MonadCancelThrow instances", "3.6.0") - def catsEffectMonadErrorForResource[F[_], E]( + implicit def catsEffectMonadErrorForResource[F[_], E]( implicit F0: MonadError[F, E]): MonadError[Resource[F, *], E] = new ResourceMonadError[F, E] { def F = F0