File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed
compiler/src/dotty/tools/dotc/core Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -1954,12 +1954,11 @@ class TypeComparer(@constructorOnly initctx: Context) extends ConstraintHandling
19541954 val info1 = m.info.widenExpr
19551955 isSubInfo(info1, tp2.refinedInfo.widenExpr, m.symbol.info.orElse(info1))
19561956 || matchAbstractTypeMember(m.info)
1957+ || (tp1.isStable && isSubType(TermRef (tp1, m.symbol), tp2.refinedInfo))
19571958
1958- def memberQualifies = tp1.member(name) match // inlined hasAltWith for performance
1959+ tp1.member(name) match // inlined hasAltWith for performance
19591960 case mbr : SingleDenotation => qualifies(mbr)
19601961 case mbr => mbr hasAltWith qualifies
1961-
1962- memberQualifies || (tp1.isStable && isSub(TermRef (tp1, name), tp2.refinedInfo))
19631962 }
19641963
19651964 final def ensureStableSingleton (tp : Type ): SingletonType = tp.stripTypeVar match {
You can’t perform that action at this time.
0 commit comments