We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cb15213 commit af5010dCopy full SHA for af5010d
compiler/src/dotty/tools/dotc/core/GadtConstraint.scala
@@ -167,6 +167,9 @@ final class ProperGadtConstraint private(
167
// class Foo[F[t] >: List[t]]
168
// type T = Foo[List]
169
// precisely because Foo[List] is desugared to Foo[[A] => List[A]].
170
+ //
171
+ // Ideally we'd adapt the bound in ConstraintHandling#addOneBound,
172
+ // but doing it there actually interferes with type inference.
173
val bound1 = bound.adaptHkVariances(oldUpperBound)
174
if (isUpper) addUpperBound(symTvar.origin, bound1)
175
else addLowerBound(symTvar.origin, bound1)
0 commit comments