Widen parLiftN's constraint to NonEmptyParallel
Drafting to see what mima says...
Unfortunately we have no MiMa support here, because syntax classes are private (which MiMa correctly ignores).
It's arguably a bug that methods on private classes are publicly usable.
- https://github.com/scala/bug/issues/6794
okay, I was able to follow your advice from Discord and just created a new copy of the syntax class, except the old implicit conversion has been made non-implicit.
I tested it with the following:
main.scala:
//> using dep org.typelevel::cats-core:2.13.0
import cats.syntax.all.*
case class Foo(a: Int, b: String)
object demo extends App {
def foo(a: Either[String, Int], b: Either[String, String]) = (Foo.apply _).parLiftN(a, b)
println(foo(Left("error"), Right("hello")))
}
run.sh:
#!/usr/bin/env bash
set -e
set -x
for sv in 2.12 2.13 3
do
echo "compiling $sv"
if [ "$sv" == "2.12" ]; then
EXTRA_FLAGS="-Ypartial-unification"
else
EXTRA_FLAGS=""
fi
scala-cli compile main.scala --output-directory out --scala "$sv" -Xsource:3 $EXTRA_FLAGS
DEPS=$(cs fetch org.typelevel:cats-core_$sv:2.13.0-4-2d82b53-SNAPSHOT --classpath)
echo "running: "
java -cp "$DEPS:out" 'demo'
done
It succeeds in all versions. Does that sound about right?
I mean... parLiftN and friends just have been released... Can we consider risking it and ignore the binary incompatibilities there? We could quickly arrange 2.13.1 and recommend to hold on upgrading to 2.13.0 😅
Maybe no one even notice :)
Your call 😅