fix: Fixes infer-any warning on F[_]#11157
Conversation
c89c8ed to
0024ebe
Compare
**Problem** infer-any linter warns on F[_] when the function is curried. **Solution** Don't warn when the inference is retractable, which is Nothing.
0024ebe to
c473417
Compare
|
Thoughs / observations:
class Bar
class Test {
def f[F[_], A](v: F[A]) = v
implicit def barToList(b: Bar): List[Int] = List(42)
def t1 = f(new Bar) // warns in 2.13.16, two warnings in 2.13.17
def t2: Any = f(new Bar) // no warning in 2.13.16, new 'kind-polymorphic' warning in 2.13.17
}That's because the
So I think we should revert the new warning for the Perhaps also revert it for the |
|
Yea, the ratio of kind-checking saving the day vs posing issues does not seem great, so I'm supportive of just reverting the whole thing. |
Fixes scala/bug#13128
Problem
infer-any linter warns on
F[_]when the function is curried.Solution
Don't warn when the inference is retractable, which is Nothing.