@@ -319,7 +319,7 @@ class TypeComparer(initctx: Context) extends ConstraintHandling {
319
319
thirdTry
320
320
case tp1 : TypeParamRef =>
321
321
def flagNothingBound = {
322
- if (! frozenConstraint && tp2.isRef(defn. NothingClass ) && state.isGlobalCommittable) {
322
+ if (! frozenConstraint && tp2.isRef(NothingClass ) && state.isGlobalCommittable) {
323
323
def msg = s " !!! instantiated to Nothing: $tp1, constraint = ${constraint.show}"
324
324
if (Config .failOnInstantiationToNothing) assert(false , msg)
325
325
else ctx.log(msg)
@@ -404,7 +404,7 @@ class TypeComparer(initctx: Context) extends ConstraintHandling {
404
404
if (cls2.isClass) {
405
405
if (cls2.typeParams.isEmpty) {
406
406
if (cls2 eq AnyKindClass ) return true
407
- if (tp1.isRef(defn. NothingClass )) return true
407
+ if (tp1.isRef(NothingClass )) return true
408
408
if (tp1.isLambdaSub) return false
409
409
// Note: We would like to replace this by `if (tp1.hasHigherKind)`
410
410
// but right now we cannot since some parts of the standard library rely on the
@@ -417,7 +417,7 @@ class TypeComparer(initctx: Context) extends ConstraintHandling {
417
417
val base = tp1.baseType(cls2)
418
418
if (base.typeSymbol == cls2) return true
419
419
}
420
- else if (tp1.isLambdaSub && ! tp1.isRef(defn. AnyKindClass ))
420
+ else if (tp1.isLambdaSub && ! tp1.isRef(AnyKindClass ))
421
421
return recur(tp1, EtaExpansion (cls2.typeRef))
422
422
}
423
423
fourthTry
@@ -1382,7 +1382,7 @@ class TypeComparer(initctx: Context) extends ConstraintHandling {
1382
1382
// at run time. It would not work to replace that with `Nothing`.
1383
1383
// However, maybe we can still apply the replacement to
1384
1384
// types which are not explicitly written.
1385
- defn. NothingType
1385
+ NothingType
1386
1386
case _ => andType(tp1, tp2)
1387
1387
}
1388
1388
case _ => andType(tp1, tp2)
@@ -1393,8 +1393,7 @@ class TypeComparer(initctx: Context) extends ConstraintHandling {
1393
1393
}
1394
1394
1395
1395
/** The greatest lower bound of a list types */
1396
- final def glb (tps : List [Type ]): Type =
1397
- ((defn.AnyType : Type ) /: tps)(glb)
1396
+ final def glb (tps : List [Type ]): Type = ((AnyType : Type ) /: tps)(glb)
1398
1397
1399
1398
/** The least upper bound of two types
1400
1399
* @param canConstrain If true, new constraints might be added to simplify the lub.
@@ -1424,7 +1423,7 @@ class TypeComparer(initctx: Context) extends ConstraintHandling {
1424
1423
1425
1424
/** The least upper bound of a list of types */
1426
1425
final def lub (tps : List [Type ]): Type =
1427
- ((defn. NothingType : Type ) /: tps)(lub(_,_, canConstrain = false ))
1426
+ ((NothingType : Type ) /: tps)(lub(_,_, canConstrain = false ))
1428
1427
1429
1428
/** Try to produce joint arguments for a lub `A[T_1, ..., T_n] | A[T_1', ..., T_n']` using
1430
1429
* the following strategies:
0 commit comments