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 @@ -230,13 +230,13 @@ class TyperState() {
230230 val tvars = tl.paramRefs.map(other.typeVarOfParam(_)).collect { case tv : TypeVar => tv }
231231 if this .isCommittable then
232232 tvars.foreach(tvar =>
233- if ! tvar.inst.exists then
234- if ! isOwnedAnywhere(this , tvar) then includeVar(tvar)
235- if constraint.isHard(tvar) then constraint = constraint.withHard(tvar))
233+ if ! tvar.inst.exists && ! isOwnedAnywhere(this , tvar) then includeVar(tvar))
236234 typeComparer.addToConstraint(tl, tvars)
237235 }) &&
238236 // Integrate the additional constraints on type variables from `other`
237+ // and merge hardness markers
239238 constraint.uninstVars.forall(tv =>
239+ if other.isHard(tv) then constraint = constraint.withHard(tv)
240240 val p = tv.origin
241241 val otherLos = other.lower(p)
242242 val otherHis = other.upper(p)
You can’t perform that action at this time.
0 commit comments