Skip to content

Commit f5a5867

Browse files
committed
Fix errors under Scala 3.6.3
1 parent 32a50dc commit f5a5867

37 files changed

+105
-105
lines changed

algebra-core/src/main/scala/algebra/ring/EuclideanRing.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ trait EuclideanRing[@sp(Int, Long, Float, Double) A] extends Any with GCDRing[A]
4646
def emod(a: A, b: A): A
4747
def equotmod(a: A, b: A): (A, A) = (equot(a, b), emod(a, b))
4848
def gcd(a: A, b: A)(implicit ev: Eq[A]): A =
49-
EuclideanRing.euclid(a, b)(ev, self)
49+
EuclideanRing.euclid(a, b)(using ev, self)
5050
def lcm(a: A, b: A)(implicit ev: Eq[A]): A =
5151
if (isZero(a) || isZero(b)) zero else times(equot(a, gcd(a, b)), b)
5252
}

algebra-laws/shared/src/test/scala/algebra/laws/LawTests.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ class LawTests extends munit.DisciplineSuite {
134134
Arbitrary(arbitrary[Double].map(x => BigDecimal(x, mc)))
135135
implicit val epsBigDecimal = FPApprox.Epsilon.bigDecimalEpsilon(mc)
136136
implicit val algebra: FPApproxAlgebra[BigDecimal] =
137-
FPApprox.fpApproxAlgebra(new BigDecimalAlgebra(mc), Order[BigDecimal], epsBigDecimal)
137+
FPApprox.fpApproxAlgebra(using new BigDecimalAlgebra(mc), Order[BigDecimal], epsBigDecimal)
138138
checkAll("FPApprox[BigDecimal]", RingLaws[FPApprox[BigDecimal]].field(algebra))
139139
}
140140
} else ()

algebra-laws/shared/src/test/scala/algebra/laws/Rat.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ object Rat {
118118
new RatAlgebra
119119

120120
val RatMinMaxLattice: DistributiveLattice[Rat] =
121-
DistributiveLattice.minMax[Rat](ratAlgebra)
121+
DistributiveLattice.minMax[Rat](using ratAlgebra)
122122

123123
// Is this horrible? Yes. Am I ashamed? Yes.
124124
private[this] def genNonZero: Gen[BigInt] =

bench/src/main/scala/cats/bench/ParTraverseBench.scala

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,28 +46,28 @@ class ParTraverseBench {
4646
val f: Int => Either[Int, Int] = Right(_)
4747

4848
def parTraversePointfree[T[_]: Traverse, M[_], A, B](ta: T[A])(f: A => M[B])(implicit P: Parallel[M]): M[T[B]] = {
49-
val gtb: P.F[T[B]] = Traverse[T].traverse(ta)(f.andThen(P.parallel.apply(_)))(P.applicative)
49+
val gtb: P.F[T[B]] = Traverse[T].traverse(ta)(f.andThen(P.parallel.apply(_)))(using P.applicative)
5050
P.sequential(gtb)
5151
}
5252

5353
def parTraversePointfull[T[_]: Traverse, M[_], A, B](ta: T[A])(f: A => M[B])(implicit P: Parallel[M]): M[T[B]] = {
54-
val gtb: P.F[T[B]] = Traverse[T].traverse(ta)(a => P.parallel(f(a)))(P.applicative)
54+
val gtb: P.F[T[B]] = Traverse[T].traverse(ta)(a => P.parallel(f(a)))(using P.applicative)
5555
P.sequential(gtb)
5656
}
5757

5858
def parBitraversePointfree[T[_, _]: Bitraverse, M[_], A, B, C, D](
5959
tab: T[A, B]
6060
)(f: A => M[C], g: B => M[D])(implicit P: Parallel[M]): M[T[C, D]] = {
6161
val ftcd: P.F[T[C, D]] =
62-
Bitraverse[T].bitraverse(tab)(f.andThen(P.parallel.apply(_)), g.andThen(P.parallel.apply(_)))(P.applicative)
62+
Bitraverse[T].bitraverse(tab)(f.andThen(P.parallel.apply(_)), g.andThen(P.parallel.apply(_)))(using P.applicative)
6363
P.sequential(ftcd)
6464
}
6565

6666
def parBitraversePointfull[T[_, _]: Bitraverse, M[_], A, B, C, D](
6767
tab: T[A, B]
6868
)(f: A => M[C], g: B => M[D])(implicit P: Parallel[M]): M[T[C, D]] = {
6969
val ftcd: P.F[T[C, D]] =
70-
Bitraverse[T].bitraverse(tab)(a => P.parallel.apply(f(a)), b => P.parallel.apply(g(b)))(P.applicative)
70+
Bitraverse[T].bitraverse(tab)(a => P.parallel.apply(f(a)), b => P.parallel.apply(g(b)))(using P.applicative)
7171
P.sequential(ftcd)
7272
}
7373

core/src/main/scala/cats/Parallel.scala

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ object Parallel extends ParallelArityFunctions2 {
224224
* corresponding to the Parallel instance instead.
225225
*/
226226
def parSequence[T[_]: Traverse, M[_], A](tma: T[M[A]])(implicit P: Parallel[M]): M[T[A]] = {
227-
val fta: P.F[T[A]] = Traverse[T].traverse(tma)(P.parallel.apply(_))(P.applicative)
227+
val fta: P.F[T[A]] = Traverse[T].traverse(tma)(P.parallel.apply(_))(using P.applicative)
228228
P.sequential(fta)
229229
}
230230

@@ -233,7 +233,7 @@ object Parallel extends ParallelArityFunctions2 {
233233
* corresponding to the Parallel instance instead.
234234
*/
235235
def parTraverse[T[_]: Traverse, M[_], A, B](ta: T[A])(f: A => M[B])(implicit P: Parallel[M]): M[T[B]] = {
236-
val gtb: P.F[T[B]] = Traverse[T].traverse(ta)(a => P.parallel(f(a)))(P.applicative)
236+
val gtb: P.F[T[B]] = Traverse[T].traverse(ta)(a => P.parallel(f(a)))(using P.applicative)
237237
P.sequential(gtb)
238238
}
239239

@@ -320,7 +320,7 @@ object Parallel extends ParallelArityFunctions2 {
320320
def parNonEmptySequence[T[_]: NonEmptyTraverse, M[_], A](
321321
tma: T[M[A]]
322322
)(implicit P: NonEmptyParallel[M]): M[T[A]] = {
323-
val fta: P.F[T[A]] = NonEmptyTraverse[T].nonEmptyTraverse(tma)(P.parallel.apply(_))(P.apply)
323+
val fta: P.F[T[A]] = NonEmptyTraverse[T].nonEmptyTraverse(tma)(P.parallel.apply(_))(using P.apply)
324324
P.sequential(fta)
325325
}
326326

@@ -331,7 +331,7 @@ object Parallel extends ParallelArityFunctions2 {
331331
def parNonEmptyTraverse[T[_]: NonEmptyTraverse, M[_], A, B](
332332
ta: T[A]
333333
)(f: A => M[B])(implicit P: NonEmptyParallel[M]): M[T[B]] = {
334-
val gtb: P.F[T[B]] = NonEmptyTraverse[T].nonEmptyTraverse(ta)(a => P.parallel(f(a)))(P.apply)
334+
val gtb: P.F[T[B]] = NonEmptyTraverse[T].nonEmptyTraverse(ta)(a => P.parallel(f(a)))(using P.apply)
335335
P.sequential(gtb)
336336
}
337337

@@ -408,7 +408,7 @@ object Parallel extends ParallelArityFunctions2 {
408408
tab: T[A, B]
409409
)(f: A => M[C], g: B => M[D])(implicit P: Parallel[M]): M[T[C, D]] = {
410410
val ftcd: P.F[T[C, D]] =
411-
Bitraverse[T].bitraverse(tab)(a => P.parallel(f(a)), b => P.parallel(g(b)))(P.applicative)
411+
Bitraverse[T].bitraverse(tab)(a => P.parallel(f(a)), b => P.parallel(g(b)))(using P.applicative)
412412
P.sequential(ftcd)
413413
}
414414

@@ -419,7 +419,7 @@ object Parallel extends ParallelArityFunctions2 {
419419
def parBisequence[T[_, _]: Bitraverse, M[_], A, B](
420420
tmamb: T[M[A], M[B]]
421421
)(implicit P: Parallel[M]): M[T[A, B]] = {
422-
val ftab: P.F[T[A, B]] = Bitraverse[T].bitraverse(tmamb)(P.parallel.apply(_), P.parallel.apply(_))(P.applicative)
422+
val ftab: P.F[T[A, B]] = Bitraverse[T].bitraverse(tmamb)(P.parallel.apply(_), P.parallel.apply(_))(using P.applicative)
423423
P.sequential(ftab)
424424
}
425425

@@ -431,7 +431,7 @@ object Parallel extends ParallelArityFunctions2 {
431431
tab: T[A, B]
432432
)(f: A => M[C])(implicit P: Parallel[M]): M[T[C, B]] = {
433433
val ftcb: P.F[T[C, B]] =
434-
Bitraverse[T].bitraverse(tab)(a => P.parallel.apply(f(a)), P.applicative.pure(_))(P.applicative)
434+
Bitraverse[T].bitraverse(tab)(a => P.parallel.apply(f(a)), P.applicative.pure(_))(using P.applicative)
435435
P.sequential(ftcb)
436436
}
437437

@@ -442,7 +442,7 @@ object Parallel extends ParallelArityFunctions2 {
442442
def parLeftSequence[T[_, _]: Bitraverse, M[_], A, B](
443443
tmab: T[M[A], B]
444444
)(implicit P: Parallel[M]): M[T[A, B]] = {
445-
val ftab: P.F[T[A, B]] = Bitraverse[T].bitraverse(tmab)(P.parallel.apply(_), P.applicative.pure(_))(P.applicative)
445+
val ftab: P.F[T[A, B]] = Bitraverse[T].bitraverse(tmab)(P.parallel.apply(_), P.applicative.pure(_))(using P.applicative)
446446
P.sequential(ftab)
447447
}
448448

core/src/main/scala/cats/Representable.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ trait Representable[F[_]] extends Serializable { self =>
8484
G: Representable[G]
8585
): Representable.Aux[λ[α => F[G[α]]], (self.Representation, G.Representation)] =
8686
new Representable[λ[α => F[G[α]]]] { inner =>
87-
override val F = self.F.compose(G.F)
87+
override val F = self.F.compose(using G.F)
8888

8989
type Representation = (self.Representation, G.Representation)
9090

core/src/main/scala/cats/UnorderedFoldable.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ trait UnorderedFoldable[F[_]] extends Serializable {
5454
def unorderedFoldMapA[G[_], A, B](fa: F[A])(
5555
f: A => G[B]
5656
)(implicit G: CommutativeApplicative[G], B: CommutativeMonoid[B]): G[B] =
57-
unorderedFoldMap(fa)(f)(CommutativeApplicative.commutativeMonoidFor)
57+
unorderedFoldMap(fa)(f)(using CommutativeApplicative.commutativeMonoidFor)
5858

5959
/**
6060
* Tests if `fa` contains `v` using the `Eq` instance for `A`
@@ -77,15 +77,15 @@ trait UnorderedFoldable[F[_]] extends Serializable {
7777
* If there are no elements, the result is `false`.
7878
*/
7979
def exists[A](fa: F[A])(p: A => Boolean): Boolean =
80-
unorderedFoldMap(fa)(a => Eval.later(p(a)))(UnorderedFoldable.orEvalMonoid).value
80+
unorderedFoldMap(fa)(a => Eval.later(p(a)))(using UnorderedFoldable.orEvalMonoid).value
8181

8282
/**
8383
* Check whether all elements satisfy the predicate.
8484
*
8585
* If there are no elements, the result is `true`.
8686
*/
8787
def forall[A](fa: F[A])(p: A => Boolean): Boolean =
88-
unorderedFoldMap(fa)(a => Eval.later(p(a)))(UnorderedFoldable.andEvalMonoid).value
88+
unorderedFoldMap(fa)(a => Eval.later(p(a)))(using UnorderedFoldable.andEvalMonoid).value
8989

9090
/**
9191
* The size of this UnorderedFoldable.

core/src/main/scala/cats/data/Const.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,13 +86,13 @@ object Const extends ConstInstances {
8686
sealed abstract private[data] class ConstInstances extends ConstInstances0 {
8787
implicit def catsDataUpperBoundedForConst[A, B](implicit A: UpperBounded[A]): UpperBounded[Const[A, B]] =
8888
new UpperBounded[Const[A, B]] {
89-
override def partialOrder: PartialOrder[Const[A, B]] = catsDataPartialOrderForConst(A.partialOrder)
89+
override def partialOrder: PartialOrder[Const[A, B]] = catsDataPartialOrderForConst(using A.partialOrder)
9090
override def maxBound: Const[A, B] = Const(A.maxBound)
9191
}
9292

9393
implicit def catsDataLowerBoundedForConst[A, B](implicit A: LowerBounded[A]): LowerBounded[Const[A, B]] =
9494
new LowerBounded[Const[A, B]] {
95-
override def partialOrder: PartialOrder[Const[A, B]] = catsDataPartialOrderForConst(A.partialOrder)
95+
override def partialOrder: PartialOrder[Const[A, B]] = catsDataPartialOrderForConst(using A.partialOrder)
9696
override def minBound: Const[A, B] = Const(A.minBound)
9797
}
9898

core/src/main/scala/cats/data/EitherT.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1019,7 +1019,7 @@ abstract private[data] class EitherTInstances extends EitherTInstances1 {
10191019
implicit val monadM: Monad[M] = P.monad
10201020

10211021
def applicative: Applicative[Nested[P.F, Validated[E, *], *]] =
1022-
cats.data.Nested.catsDataApplicativeForNested(P.applicative, Validated.catsDataApplicativeErrorForValidated)
1022+
cats.data.Nested.catsDataApplicativeForNested(using P.applicative, Validated.catsDataApplicativeErrorForValidated)
10231023

10241024
def monad: Monad[EitherT[M, E, *]] = cats.data.EitherT.catsDataMonadErrorForEitherT
10251025

@@ -1050,7 +1050,7 @@ abstract private[data] class EitherTInstances extends EitherTInstances1 {
10501050
implicit val monadEither: Monad[Either[E, *]] = cats.instances.either.catsStdInstancesForEither
10511051

10521052
def applicative: Applicative[Nested[P.F, Either[E, *], *]] =
1053-
cats.data.Nested.catsDataApplicativeForNested(P.applicative, implicitly)
1053+
cats.data.Nested.catsDataApplicativeForNested(using P.applicative, implicitly)
10541054

10551055
def monad: Monad[EitherT[M, E, *]] = cats.data.EitherT.catsDataMonadErrorForEitherT
10561056

core/src/main/scala/cats/data/Func.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ sealed abstract class AppFunc[F[_], A, B] extends Func[F, A, B] { self =>
131131
}
132132

133133
def compose[G[_], C](g: AppFunc[G, C, A]): AppFunc[Nested[G, F, *], C, B] = {
134-
implicit val gfApplicative: Applicative[Nested[G, F, *]] = Nested.catsDataApplicativeForNested[G, F](g.F, F)
134+
implicit val gfApplicative: Applicative[Nested[G, F, *]] = Nested.catsDataApplicativeForNested[G, F](using g.F, F)
135135
Func.appFunc[Nested[G, F, *], C, B] { (c: C) =>
136136
Nested(g.F.map(g.run(c))(self.run))
137137
}
@@ -146,7 +146,7 @@ sealed abstract class AppFunc[F[_], A, B] extends Func[F, A, B] { self =>
146146
}
147147

148148
def traverse[G[_]](ga: G[A])(implicit GG: Traverse[G]): F[G[B]] =
149-
GG.traverse(ga)(self.run)(F)
149+
GG.traverse(ga)(self.run)(using F)
150150
}
151151

152152
object AppFunc extends AppFuncInstances

core/src/main/scala/cats/data/Nested.scala

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ sealed abstract private[data] class NestedInstances0 extends NestedInstances1 {
118118
val FG = F0.compose(G0)
119119

120120
val F: Functor[Nested[F, G, *]] = new NestedFunctor[F, G] {
121-
val FG = F0.F.compose(G0.F)
121+
val FG = F0.F.compose(using G0.F)
122122
}
123123

124124
type Representation = FG.Representation
@@ -301,7 +301,7 @@ abstract private[data] class NestedApplicativeError[F[_], G[_], E]
301301
def G: Applicative[G]
302302
def AEF: ApplicativeError[F, E]
303303

304-
def FG: Applicative[λ[α => F[G[α]]]] = AEF.compose[G](G)
304+
def FG: Applicative[λ[α => F[G[α]]]] = AEF.compose[G](using G)
305305

306306
def raiseError[A](e: E): Nested[F, G, A] = Nested(AEF.map(AEF.raiseError[A](e))(G.pure))
307307

@@ -421,7 +421,7 @@ abstract private[data] class NestedFunctorFilter[F[_], G[_]] extends FunctorFilt
421421

422422
implicit val G: FunctorFilter[G]
423423

424-
def functor: Functor[Nested[F, G, *]] = Nested.catsDataFunctorForNested(F, G.functor)
424+
def functor: Functor[Nested[F, G, *]] = Nested.catsDataFunctorForNested(using F, G.functor)
425425

426426
def mapFilter[A, B](fa: Nested[F, G, A])(f: (A) => Option[B]): Nested[F, G, B] =
427427
Nested[F, G, B](F.map(fa.value)(G.mapFilter(_)(f)))
@@ -447,7 +447,7 @@ abstract private[data] class NestedTraverseFilter[F[_], G[_]]
447447

448448
implicit val G: TraverseFilter[G]
449449

450-
def traverse: Traverse[Nested[F, G, *]] = Nested.catsDataTraverseForNested(F, G.traverse)
450+
def traverse: Traverse[Nested[F, G, *]] = Nested.catsDataTraverseForNested(using F, G.traverse)
451451

452452
override def filterA[H[_], A](
453453
fa: Nested[F, G, A]
@@ -465,7 +465,7 @@ abstract private[data] class NestedAlign[F[_], G[_]] extends Align[Nested[F, G,
465465
implicit val G: Align[G]
466466

467467
override def functor: Functor[Nested[F, G, *]] =
468-
Nested.catsDataFunctorForNested(F.functor, G.functor)
468+
Nested.catsDataFunctorForNested(using F.functor, G.functor)
469469

470470
override def align[A, B](
471471
fa: Nested[F, G, A],

core/src/main/scala/cats/data/NonEmptyMapImpl.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,7 @@ sealed abstract private[data] class NonEmptyMapInstances extends NonEmptyMapInst
362362

363363
@deprecated("Use catsDataHashForNonEmptyMap override without Order", "2.2.0-M3")
364364
def catsDataHashForNonEmptyMap[K, A](hashK: Hash[K], orderK: Order[K], hashA: Hash[A]): Hash[NonEmptyMap[K, A]] =
365-
catsDataHashForNonEmptyMap(hashK, hashA)
365+
catsDataHashForNonEmptyMap(using hashK, hashA)
366366

367367
implicit def catsDataShowForNonEmptyMap[K: Show, A: Show]: Show[NonEmptyMap[K, A]] = _.show
368368

@@ -378,5 +378,5 @@ sealed abstract private[data] class NonEmptyMapInstances0 {
378378

379379
@deprecated("Use catsDataEqForNonEmptyMap override without Order", "2.2.0-M3")
380380
def catsDataEqForNonEmptyMap[K, A](orderK: Order[K], eqA: Eq[A]): Eq[NonEmptyMap[K, A]] =
381-
catsDataEqForNonEmptyMap(eqA)
381+
catsDataEqForNonEmptyMap(using eqA)
382382
}

core/src/main/scala/cats/data/OptionT.scala

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -609,7 +609,7 @@ final case class OptionT[F[_], A](value: F[Option[A]]) {
609609
* }}}
610610
*/
611611
def traverse[G[_], B](f: A => G[B])(implicit F: Traverse[F], G: Applicative[G]): G[OptionT[F, B]] =
612-
G.map(F.compose(Traverse[Option]).traverse(value)(f))(OptionT.apply)
612+
G.map(F.compose(using Traverse[Option]).traverse(value)(f))(OptionT.apply)
613613

614614
/**
615615
* Example:
@@ -637,7 +637,7 @@ final case class OptionT[F[_], A](value: F[Option[A]]) {
637637
* }}}
638638
*/
639639
def foldLeft[B](b: B)(f: (B, A) => B)(implicit F: Foldable[F]): B =
640-
F.compose(Foldable[Option]).foldLeft(value, b)(f)
640+
F.compose(using Foldable[Option]).foldLeft(value, b)(f)
641641

642642
/**
643643
* Example:
@@ -651,7 +651,7 @@ final case class OptionT[F[_], A](value: F[Option[A]]) {
651651
* }}}
652652
*/
653653
def foldRight[B](lb: Eval[B])(f: (A, Eval[B]) => Eval[B])(implicit F: Foldable[F]): Eval[B] =
654-
F.compose(Foldable[Option]).foldRight(value, lb)(f)
654+
F.compose(using Foldable[Option]).foldRight(value, lb)(f)
655655

656656
/**
657657
* Transform this `OptionT[F, A]` into a `[[Nested]][F, Option, A]`.
@@ -858,7 +858,7 @@ sealed abstract private[data] class OptionTInstances extends OptionTInstances0 {
858858
implicit val monadM: Monad[M] = P.monad
859859

860860
def applicative: Applicative[Nested[P.F, Option, *]] =
861-
cats.data.Nested.catsDataApplicativeForNested(P.applicative, cats.instances.option.catsStdInstancesForOption)
861+
cats.data.Nested.catsDataApplicativeForNested(using P.applicative, cats.instances.option.catsStdInstancesForOption)
862862

863863
def monad: Monad[OptionT[M, *]] = cats.data.OptionT.catsDataMonadErrorMonadForOptionT[M]
864864

core/src/main/scala/cats/instances/sortedSet.scala

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ trait SortedSetInstances extends SortedSetInstances1 {
9494
private[instances] trait SortedSetInstances1 {
9595
@deprecated("Use cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet", "2.0.0-RC2")
9696
private[instances] def catsKernelStdHashForSortedSet[A: Order: Hash]: Hash[SortedSet[A]] =
97-
cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet[A](Hash[A])
97+
cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet[A](using Hash[A])
9898

9999
@deprecated("Use cats.kernel.instances.sortedSet.catsKernelStdSemilatticeForSortedSet", "2.0.0-RC2")
100100
def catsKernelStdSemilatticeForSortedSet[A: Order]: BoundedSemilattice[SortedSet[A]] =
@@ -114,11 +114,11 @@ private[instances] trait SortedSetInstancesBinCompat0 {
114114

115115
private[instances] trait SortedSetInstancesBinCompat1 extends LowPrioritySortedSetInstancesBinCompat1 {
116116
implicit def catsKernelStdHashForSortedSet1[A: Hash]: Hash[SortedSet[A]] =
117-
cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet[A](Hash[A])
117+
cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet[A](using Hash[A])
118118

119119
@deprecated("Use cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet", "2.0.0-RC3")
120120
override def catsKernelStdHashForSortedSet[A: Order: Hash]: Hash[SortedSet[A]] =
121-
cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet[A](Hash[A])
121+
cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet[A](using Hash[A])
122122
}
123123

124124
private[instances] trait LowPrioritySortedSetInstancesBinCompat1
@@ -128,11 +128,11 @@ private[instances] trait LowPrioritySortedSetInstancesBinCompat1
128128
cats.kernel.instances.sortedSet.catsKernelStdOrderForSortedSet[A]
129129

130130
implicit override def catsKernelStdHashForSortedSet[A: Hash]: Hash[SortedSet[A]] =
131-
cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet[A](Hash[A])
131+
cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet[A](using Hash[A])
132132

133133
@deprecated("Use cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet", "2.0.0-RC2")
134134
override def catsKernelStdHashForSortedSet[A: Order: Hash]: Hash[SortedSet[A]] =
135-
cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet[A](Hash[A])
135+
cats.kernel.instances.sortedSet.catsKernelStdHashForSortedSet[A](using Hash[A])
136136
}
137137

138138
@deprecated("Use cats.kernel.instances.SortedSetHash", "2.0.0-RC2")

free/src/test/scala/cats/free/FreeSuite.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -233,8 +233,8 @@ class FreeSuite extends CatsSuite {
233233
f: Free[F, A]
234234
)(implicit F: Functor[F], I0: Test1Algebra :<: F, I1: Test2Algebra :<: F): Option[Free[F, A]] =
235235
for {
236-
Test1(x, h) <- Free.match_[F, Test1Algebra, A](f)
237-
Test2(y, k) <- Free.match_[F, Test2Algebra, A](h(x))
236+
case Test1(x, h) <- Free.match_[F, Test1Algebra, A](f)
237+
case Test2(y, k) <- Free.match_[F, Test2Algebra, A](h(x))
238238
} yield k(x + y)
239239

240240
forAll { (x: Int, y: Int) =>

0 commit comments

Comments
 (0)