-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ambiguous contains_
syntax
#4244
Comments
Aha, here's a reproducer. The issue seems to be when using it as a lambda. //> using scala "2.13.8"
//> using lib "org.typelevel::cats-core::2.8.0"
import cats.syntax.all._
object Test {
def main(args: Array[String]): Unit = println(List("a").map(List("a").contains_))
}
|
Rewriting as |
I guess it has to be fixes in the compiler - it works in Scala 3. |
It does but only because we rewrote the argument list to be |
Oh ok I see - it's a trick that changed the method signature but not binary compatibility. |
Nobody else has complained, this is annoying to fix, and there's an easy workaround. I'm going to put this on the backlog. |
Came across this a bunch today when I upgraded to 2.8.0 on 2.13.8. Hope to upgrade to Scala 3 soon with this project but just FYI. |
Darn, just when I thought I got away with it! Thanks for letting us know. |
Similar here. Just fyi, workaround is easy enough. |
I opened scala/bug#12666 with a minimizer of this issue. Also, I might have an idea to solve it. |
Frustrating I can't make a small reproducer, but here it is in the wild.
https://github.com/gemini-hlsw/explore/runs/6928906317?check_suite_focus=true#step:7:56
The problem is that:
cats/core/src/main/scala/cats/syntax/unorderedFoldable.scala
Line 47 in 9839b74
conflicts with
cats/core/src/main/scala/cats/syntax/foldable.scala
Line 73 in 9839b74
This is related to scala/bug#12578.
I thought we worked through it in #4183 since I linked it in that ticket, but seems there are still problems in some situations 🤔
The text was updated successfully, but these errors were encountered: