Skip to content

Commit dee56dd

Browse files
committed
Fix indentation of code
1 parent 5b98c4f commit dee56dd

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

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

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -223,27 +223,27 @@ final class ProperGadtConstraint private(
223223
override protected def isSub(tp1: Type, tp2: Type)(using Context): Boolean = TypeComparer.isSubType(tp1, tp2)
224224
override protected def isSame(tp1: Type, tp2: Type)(using Context): Boolean = TypeComparer.isSameType(tp1, tp2)
225225

226-
override def nonParamBounds(param: TypeParamRef)(using Context): TypeBounds =
227-
val externalizeMap = new TypeMap {
228-
def apply(tp: Type): Type = tp match {
229-
case tpr: TypeParamRef => externalize(tpr)
230-
case tp => mapOver(tp)
231-
}
232-
}
233-
externalizeMap(constraint.nonParamBounds(param)).bounds
234-
235-
override def fullLowerBound(param: TypeParamRef)(using Context): Type =
236-
constraint.minLower(param).foldLeft(nonParamBounds(param).lo) {
237-
(t, u) => t | externalize(u)
238-
}
239-
240-
override def fullUpperBound(param: TypeParamRef)(using Context): Type =
241-
constraint.minUpper(param).foldLeft(nonParamBounds(param).hi) { (t, u) =>
242-
val eu = externalize(u)
243-
// Any as the upper bound means "no bound", but if F is higher-kinded,
244-
// Any & F = F[_]; this is wrong for us so we need to short-circuit
245-
if t.isAny then eu else t & eu
246-
}
226+
override def nonParamBounds(param: TypeParamRef)(using Context): TypeBounds =
227+
val externalizeMap = new TypeMap {
228+
def apply(tp: Type): Type = tp match {
229+
case tpr: TypeParamRef => externalize(tpr)
230+
case tp => mapOver(tp)
231+
}
232+
}
233+
externalizeMap(constraint.nonParamBounds(param)).bounds
234+
235+
override def fullLowerBound(param: TypeParamRef)(using Context): Type =
236+
constraint.minLower(param).foldLeft(nonParamBounds(param).lo) {
237+
(t, u) => t | externalize(u)
238+
}
239+
240+
override def fullUpperBound(param: TypeParamRef)(using Context): Type =
241+
constraint.minUpper(param).foldLeft(nonParamBounds(param).hi) { (t, u) =>
242+
val eu = externalize(u)
243+
// Any as the upper bound means "no bound", but if F is higher-kinded,
244+
// Any & F = F[_]; this is wrong for us so we need to short-circuit
245+
if t.isAny then eu else t & eu
246+
}
247247

248248
// ---- Private ----------------------------------------------------------
249249

0 commit comments

Comments
 (0)