@@ -96,11 +96,11 @@ object TypeErasure {
9696 val arity2 = tupleArity(tp.tp2)
9797 if arity1 == arity2 then arity1 else math.min(- 1 , math.min(arity1, arity2))
9898 case tp : WildcardType => - 2
99- case tp : TypeVar if ! tp.inst.exists => - 2
99+ case tp : TypeVar if ! tp.isInstantiated => - 2
100100 case _ =>
101101 if defn.isTupleNType(tp) then tp.dealias.argInfos.length
102102 else tp.dealias match
103- case tp : TypeVar if ! tp.inst.exists => - 2
103+ case tp : TypeVar if ! tp.isInstantiated => - 2
104104 case _ => - 1
105105
106106 def normalizeClass (cls : ClassSymbol )(using Context ): ClassSymbol = {
@@ -660,8 +660,8 @@ class TypeErasure(sourceLanguage: SourceLanguage, semiEraseVCs: Boolean, isConst
660660 erasePolyFunctionApply(refinedInfo)
661661 case RefinedType (parent, nme.apply, refinedInfo : MethodType ) if defn.isErasedFunctionType(parent) =>
662662 eraseErasedFunctionApply(refinedInfo)
663- case tp : TypeVar if ! tp.inst.exists =>
664- assert(inSigName, i " Cannot erase non-permanently instantiated type variable $tp" )
663+ case tp : TypeVar if ! tp.isInstantiated =>
664+ assert(inSigName, i " Cannot erase uninstantiated type variable $tp" )
665665 null
666666 case tp : TypeProxy =>
667667 this (tp.underlying)
@@ -945,7 +945,7 @@ class TypeErasure(sourceLanguage: SourceLanguage, semiEraseVCs: Boolean, isConst
945945 sigName(underlyingOfTermRef(tp))
946946 case ExprType (rt) =>
947947 sigName(defn.FunctionOf (Nil , rt))
948- case tp : TypeVar if ! tp.inst.exists =>
948+ case tp : TypeVar if ! tp.isInstantiated =>
949949 tpnme.Uninstantiated
950950 case tp @ RefinedType (parent, nme.apply, _) if parent.typeSymbol eq defn.PolyFunctionClass =>
951951 // we need this case rather than falling through to the default
0 commit comments