Skip to content

Commit 03b5a7c

Browse files
committed
Drop special case skipping singletons in TypeComparer
1 parent fc7ca99 commit 03b5a7c

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

compiler/src/dotty/tools/dotc/core/TypeComparer.scala

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -573,12 +573,6 @@ class TypeComparer(initctx: Context) extends ConstraintHandling[AbsentContext] {
573573
}
574574
compareTypeLambda
575575
case OrType(tp21, tp22) =>
576-
val tp1a = tp1.widenDealiasKeepRefiningAnnots
577-
if (tp1a ne tp1)
578-
// Follow the alias; this might avoid truncating the search space in the either below
579-
// Note that it's safe to widen here because singleton types cannot be part of `|`.
580-
return recur(tp1a, tp2)
581-
582576
// Rewrite T1 <: (T211 & T212) | T22 to T1 <: (T211 | T22) and T1 <: (T212 | T22)
583577
// and analogously for T1 <: T21 | (T221 & T222)
584578
// `|' types to the right of <: are problematic, because

0 commit comments

Comments
 (0)