We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
import language._ object Test { (null: Any) match { case a: A[k] => new B[k]() } } class A[K[L[_]]] class B[K[L[_]]]
This used to work in 2.10.x by virtue of a bug in refchecks (#7756)
Test case minimized from sbt, in util/collection/src/main/scala/sbt/INode.scala
Type variables already pick up the bounds:
import language._ object Test { (null: Any) match { case a: A[k] => new B[k]() } } class A[K <: String] class B[K <: String]
The text was updated successfully, but these errors were encountered:
Imported From: https://issues.scala-lang.org/browse/SI-8023?orig=1 Reporter: @retronym See #7756
Sorry, something went wrong.
@retronym said: Oh man, this one depends on compilation order: this works:
class A[K[L[_]]] class B[K[L[_]]] object Test { (null: Any) match { case a: A[k] => new B[k]() } }
The condition in question:
if (!isComplete) args mapConserve (typedHigherKindedType(_, mode)) // if symbol hasn't been fully loaded, can't check kind-arity else map2Conserve(args, tparams) { (arg, tparam) => //@M! the polytype denotes the expected kind typedHigherKindedType(arg, mode, GenPolyType(tparam.typeParams, AnyTpe)) }
@retronym said: We might be able to make this work in the same place that we enhanceBounds.
enhanceBounds
@retronym said: Here's what's required to make this work in typedBind (the "bull in the china store" approach of not trying to avoid cycles)
typedBind
https://github.com/retronym/scala/compare/ticket;8023?expand=1
@retronym said: See: scala/scala@218c5a8223 "previous change caused cyclic references.."
@adriaanm said: Always scary to see that "authored 7 years ago", especially when prefixed with your own name.
@retronym said: It might be best to change ones name by deed poll after a decent stretch of time in one codebase.
PR: scala/scala#3212
retronym
No branches or pull requests
This used to work in 2.10.x by virtue of a bug in refchecks (#7756)
Test case minimized from sbt, in util/collection/src/main/scala/sbt/INode.scala
Type variables already pick up the bounds:
The text was updated successfully, but these errors were encountered: