TypeMap

dotty.tools.dotc.core.Types.TypeMap
abstract class TypeMap(implicit var mapCtx: Context) extends VariantTraversal, Type => Type

Attributes

Graph
Supertypes
trait Type => Type
class Object
trait Matchable
class Any
Known subtypes
Self type

Members list

Value members

Abstract methods

def apply(tp: Type): Type

Concrete methods

def andThen(f: Type => Type): TypeMap
protected def derivedAlias(tp: AliasingBounds, alias: Type): Type
protected def derivedAndType(tp: AndType, tp1: Type, tp2: Type): Type
protected def derivedAnnotatedType(tp: AnnotatedType, underlying: Type, annot: Annotation): Type
protected def derivedAppliedType(tp: AppliedType, tycon: Type, args: List[Type]): Type
protected def derivedCapturingType(tp: Type, parent: Type, refs: CaptureSet): Type
protected def derivedClassInfo(tp: ClassInfo, pre: Type): Type
protected def derivedExprType(tp: ExprType, restpe: Type): Type
protected def derivedJavaArrayType(tp: JavaArrayType, elemtp: Type): Type
protected def derivedLambdaType(tp: LambdaType)(formals: List[tp.PInfo], restpe: Type): Type
protected def derivedMatchType(tp: MatchType, bound: Type, scrutinee: Type, cases: List[Type]): Type
protected def derivedOrType(tp: OrType, tp1: Type, tp2: Type): Type
protected def derivedRecType(tp: RecType, parent: Type): Type
protected def derivedRefinedType(tp: RefinedType, parent: Type, info: Type): Type
protected def derivedSelect(tp: NamedType, pre: Type): Type
protected def derivedSkolemType(tp: SkolemType, info: Type): Type
protected def derivedSuperType(tp: SuperType, thistp: Type, supertp: Type): Type
protected def derivedTypeBounds(tp: TypeBounds, lo: Type, hi: Type): Type
protected def derivedWildcardType(tp: WildcardType, bounds: Type): Type
def isRange(tp: Type): Boolean
protected def mapArgs(args: List[Type], tparams: List[ParamInfo]): List[Type]
protected def mapCapturingType(tp: Type, parent: Type, refs: CaptureSet, v: Int): Type
protected def mapClassInfo(tp: ClassInfo): Type

Can be overridden. By default, only the prefix is mapped.

Can be overridden. By default, only the prefix is mapped.

Attributes

def mapOver(tp: Type): Type

Map this function over given type

Map this function over given type

Attributes

def mapOver(syms: List[Symbol]): List[Symbol]
def mapOver(scope: Scope): Scope
def mapOver(tree: Tree): Tree
protected def mapOverLambda(tp: LambdaType): Type

Inherited methods

def andThen[A](g: Type => A): Type => A

Attributes

Inherited from:
Function1
inline protected def atVariance[T](v: Int)(op: => T): T

Attributes

Inherited from:
VariantTraversal
def compose[A](g: A => Type): A => Type

Attributes

Inherited from:
Function1
protected def isStaticPrefix(pre: Type)(using Context): Boolean

Can the prefix of this static reference be omitted if the reference itself can be omitted? Overridden in TypeOps#avoid.

Can the prefix of this static reference be omitted if the reference itself can be omitted? Overridden in TypeOps#avoid.

Attributes

Inherited from:
VariantTraversal
protected def stopAt: StopAt

Attributes

Inherited from:
VariantTraversal
protected def stopBecauseStaticOrLocal(tp: NamedType)(using Context): Boolean

Attributes

Inherited from:
VariantTraversal
override def toString(): String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Definition Classes
Function1 -> Any
Inherited from:
Function1
protected def tyconTypeParams(tp: AppliedType)(using Context): List[ParamInfo]

The type parameters of the constructor of this applied type. Overridden in OrderingConstraint's ConstraintAwareTraversal to take account of instantiations in the constraint that are not yet propagated to the instance types of type variables.

The type parameters of the constructor of this applied type. Overridden in OrderingConstraint's ConstraintAwareTraversal to take account of instantiations in the constraint that are not yet propagated to the instance types of type variables.

Attributes

Inherited from:
VariantTraversal

Implicits

Implicits

implicit protected val mapCtx: Context