File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
compiler/src/dotty/tools/dotc/core Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -83,7 +83,7 @@ class GadtConstraint private (
8383 // B$2 had info <: B$1 and fullBounds <: B$1
8484 // We can use the info of B$2 to drop the lower-bound of B$1
8585 // and return non-bidirectional bounds B$1 <: X and B$2 <: B$1.
86- if tp.name.is( UniqueName ) && ! tp.info.hiBound.isExactlyAny && self <:< tp.info.hiBound => acc
86+ if tp.symbol.isPatternBound && ! tp.info.hiBound.isExactlyAny && self <:< tp.info.hiBound => acc
8787 case tp => acc | tp
8888 }
8989
@@ -92,7 +92,7 @@ class GadtConstraint private (
9292 constraint.minUpper(param).foldLeft(nonParamBounds(param).hi) { (acc, u) =>
9393 externalize(u) match
9494 case tp : TypeRef // same as fullLowerBounds
95- if tp.name.is( UniqueName ) && ! tp.info.loBound.isExactlyNothing && tp.info.loBound <:< self => acc
95+ if tp.symbol.isPatternBound && ! tp.info.loBound.isExactlyNothing && tp.info.loBound <:< self => acc
9696 case tp =>
9797 // Any as the upper bound means "no bound", but if F is higher-kinded,
9898 // Any & F = F[_]; this is wrong for us so we need to short-circuit
You can’t perform that action at this time.
0 commit comments