File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
compiler/src/dotty/tools/dotc/core Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -1707,13 +1707,13 @@ class TypeComparer(@constructorOnly initctx: Context) extends ConstraintHandling
17071707 val tparam = tparams2.head
17081708 val v = tparam.paramVarianceSign
17091709
1710- /** An argument test is hard if it implies a comparison A <: B where
1710+ /** An argument test is incomplete if it implies a comparison A <: B where
17111711 * A is an AndType or B is an OrType. In these cases we need to run an
17121712 * either, which can lose solutions if there are type variables involved.
17131713 * So we defer such tests to run last, on the chance that some other argument
17141714 * comparison will instantiate or constrain type variables first.
17151715 */
1716- def isHard (arg1 : Type , arg2 : Type ): Boolean =
1716+ def isIncomplete (arg1 : Type , arg2 : Type ): Boolean =
17171717 val arg1d = arg1.stripped
17181718 val arg2d = arg2.stripped
17191719 (v >= 0 ) && (arg1d.isInstanceOf [AndType ] || arg2d.isInstanceOf [OrType ])
@@ -1811,7 +1811,7 @@ class TypeComparer(@constructorOnly initctx: Context) extends ConstraintHandling
18111811 if ! canDefer
18121812 || rest1.isEmpty && deferred1.isEmpty
18131813 // skip the hardness test if this is the last argument and no previous arguments were hard
1814- || ! isHard (arg1, arg2)
1814+ || ! isIncomplete (arg1, arg2)
18151815 then
18161816 isSubArg(arg1, arg2)
18171817 && recurArgs(
You can’t perform that action at this time.
0 commit comments