dotty.tools.dotc.core

Types

Related Doc: package core

object Types

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Types
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. trait AndOrType extends Type with ValueType

  2. abstract case class AndType(tp1: Type, tp2: Type) extends CachedGroundType with AndOrType with Product with Serializable

  3. case class AnnotatedType(tpe: Type, annot: Annotation) extends UncachedProxyType with ValueType with Product with Serializable

    An annotated type tpe @ annot

  4. abstract class ApproximatingTypeMap extends TypeMap

  5. trait BindingType extends Type

    A marker trait for types that bind other types that refer to them.

    A marker trait for types that bind other types that refer to them. Instances are: PolyType, MethodType, RefinedType.

  6. abstract class BoundType extends CachedProxyType with ValueType

  7. final class CachedAndType extends AndType

  8. class CachedClassInfo extends ClassInfo

  9. final class CachedConstantType extends ConstantType

  10. final class CachedExprType extends ExprType

  11. abstract class CachedGroundType extends Type with CachedType

    Instances of this class are cached and are not proxies.

  12. final class CachedHKApply extends HKApply

  13. final class CachedJavaArrayType extends JavaArrayType

  14. final class CachedMethodType extends MethodType

  15. final class CachedOrType extends OrType

  16. abstract class CachedProxyType extends TypeProxy with CachedType

    Instances of this class are cached and are proxies.

  17. class CachedRefinedType extends RefinedType

  18. final class CachedSkolemType extends SkolemType

  19. final class CachedSuperType extends SuperType

  20. final class CachedTermRef extends TermRef

  21. final class CachedThisType extends ThisType

  22. trait CachedType extends Type

    A marker trait for cached types

  23. class CachedTypeAlias extends TypeAlias

  24. final class CachedTypeRef extends TypeRef

  25. final class CachedWildcardType extends WildcardType

  26. abstract case class ClassInfo(prefix: Type, cls: ClassSymbol, classParents: List[TypeRef], decls: Scope, selfInfo: DotClass) extends CachedGroundType with TypeType with Product with Serializable

    Roughly: the info of a class during a period.

    Roughly: the info of a class during a period.

    prefix

    The prefix on which parents, decls, and selfType need to be rebased.

    cls

    The class symbol.

    classParents

    The parent types of this class. These are all normalized to be TypeRefs by moving any refinements to be member definitions of the class itself.

    decls

    The symbols defined directly in this class.

    selfInfo

    The type of this in this class, if explicitly given, NoType otherwise. If class is compiled from source, can also be a reference to the self symbol containing the type.

  27. abstract case class ConstantType(value: Constant) extends CachedProxyType with SingletonType with Product with Serializable

    A constant type with single value.

  28. class CyclicReference extends TypeError

  29. abstract class DeepTypeMap extends TypeMap

    A type map that maps also parents and self type of a ClassInfo

  30. abstract class ErrorType extends UncachedGroundType with ValueType

  31. class ExistsAccumulator extends TypeAccumulator[Boolean]

  32. abstract case class ExprType(resType: Type) extends CachedProxyType with TermType with MethodicType with Product with Serializable

    A by-name parameter type of the form => T, or the type of a method with no parameter list.

  33. class ForeachAccumulator extends TypeAccumulator[Unit]

  34. abstract case class HKApply(tycon: Type, args: List[Type]) extends CachedProxyType with ValueType with Product with Serializable

    A higher kinded type application C[T_1, ..., T_n]

  35. class HasUnsafeNonAccumulator extends TypeAccumulator[Boolean]

  36. final class ImplicitMethodType extends MethodType

  37. case class ImportType(expr: ast.tpd.Tree) extends UncachedGroundType with Product with Serializable

    The type of an import clause tree

  38. abstract case class JavaArrayType(elemType: Type) extends CachedGroundType with ValueType with Product with Serializable

    The type of an erased array

  39. final class JavaMethodType extends MethodType

  40. case class LambdaParam(tl: PolyType, n: Int) extends TypeParamInfo with Product with Serializable

    The parameter of a type lambda

  41. case class LazyRef(refFn: () ⇒ Type) extends UncachedProxyType with ValueType with Product with Serializable

  42. class MalformedType extends TypeError

  43. class MergeError extends TypeError

  44. trait MethodOrPoly extends Type with MethodicType

  45. abstract case class MethodParam(binder: MethodType, paramNum: Int) extends ParamType with SingletonType with Product with Serializable

  46. class MethodParamImpl extends MethodParam

  47. abstract case class MethodType(paramNames: List[TermName], paramTypes: List[Type])(resultTypeExp: (MethodType) ⇒ Type) extends CachedGroundType with BindingType with TermType with MethodOrPoly with NarrowCached with Product with Serializable

  48. abstract class MethodTypeCompanion extends AnyRef

  49. trait MethodicType extends Type with TermType

    A trait that mixes in functionality for signature caching

  50. class MissingType extends TypeError

  51. abstract class NameFilter extends AnyRef

    A name filter selects or discards a member name of a type pre.

    A name filter selects or discards a member name of a type pre. To enable efficient caching, name filters have to satisfy the following invariant: If keep is a name filter, and pre has class C as a base class, then

    keep(pre, name) implies keep(C.this, name)

  52. class NamedPartsAccumulator extends TypeAccumulator[Set[NamedType]]

  53. abstract class NamedType extends CachedProxyType with ValueType

    A NamedType of the form Prefix # name

  54. trait NarrowCached extends Type

    Implementations of this trait cache the results of narrow.

  55. abstract case class OrType(tp1: Type, tp2: Type) extends CachedGroundType with AndOrType with Product with Serializable

  56. abstract class ParamType extends BoundType

  57. case class PolyParam(binder: PolyType, paramNum: Int) extends ParamType with Product with Serializable

    TODO Some docs would be nice here!

  58. class PolyType extends CachedProxyType with BindingType with MethodOrPoly

    A type lambda of the form [v_0 X_0, ..., v_n X_n] => T

  59. trait ProtoType extends Type

    A trait for proto-types, used as expected types in typer

  60. class RealTypeBounds extends TypeBounds

  61. case class RecThis(binder: RecType) extends BoundType with SingletonType with Product with Serializable

    a self-reference to an enclosing recursive type.

  62. class RecType extends RefinedOrRecType with BindingType

  63. abstract class RefinedOrRecType extends CachedProxyType with ValueType

  64. abstract case class RefinedType(parent: Type, refinedName: Name, refinedInfo: Type) extends RefinedOrRecType with Product with Serializable

    A refined type parent { refinement }

    A refined type parent { refinement }

    refinedName

    The name of the refinement declaration

  65. trait SingletonType extends TypeProxy with ValueType

    A marker trait for types that are guaranteed to contain only a single non-null value (they might contain null in addition).

  66. abstract case class SkolemType(info: Type) extends UncachedProxyType with ValueType with SingletonType with Product with Serializable

    A skolem type reference with underlying type binder.

  67. abstract case class SuperType(thistpe: Type, supertpe: Type) extends CachedProxyType with SingletonType with Product with Serializable

    The type of a super reference cls.super where thistpe is cls.this and supertpe is the type of the value referenced by super.

  68. final class TempClassInfo extends CachedClassInfo

    A class for temporary class infos where parents are not yet known.

  69. abstract case class TermRef(prefix: Type, name: TermName) extends NamedType with SingletonType with Product with Serializable

  70. class TermRefWithFixedSym extends TermRef with WithFixedSym

  71. final class TermRefWithSignature extends TermRef

  72. trait TermType extends Type

    A marker trait for types that apply only to term symbols or that represent higher-kinded types.

  73. abstract case class ThisType(tref: TypeRef) extends CachedProxyType with SingletonType with Product with Serializable

    The type cls.this

    The type cls.this

    tref

    A type ref which indicates the class cls. Note: we do not pass a class symbol directly, because symbols do not survive runs whereas typerefs do.

  74. abstract class Type extends DotClass with Hashable with Showable

    The class of types.

    The class of types. The principal subclasses and sub-objects are as follows:

    Type -+- ProxyType --+- NamedType ----+--- TypeRef | | \ | +- SingletonType-+-+- TermRef | | | | | +--- ThisType | | +--- SuperType | | +--- ConstantType | | +--- MethodParam | | +----RecThis | | +--- SkolemType | +- PolyParam | +- RefinedOrRecType -+-- RefinedType | | -+-- RecType | +- HKApply | +- TypeBounds | +- ExprType | +- AnnotatedType | +- TypeVar | +- PolyType | +- GroundType -+- AndType +- OrType +- MethodType -----+- ImplicitMethodType | +- JavaMethodType +- ClassInfo | +- NoType +- NoPrefix +- ErrorType +- WildcardType

    Note: please keep in sync with copy in docs/docs/internals/type-system.md.

  75. abstract class TypeAccumulator[T] extends (T, Type) ⇒ T

  76. abstract class TypeAlias extends TypeBounds

  77. abstract case class TypeBounds(lo: Type, hi: Type) extends CachedProxyType with TypeType with Product with Serializable

    Type bounds >: lo <: hi

  78. class TypeError extends Exception

  79. abstract class TypeMap extends (Type) ⇒ Type

  80. abstract class TypeProxy extends Type

    A marker trait for type proxies.

    A marker trait for type proxies. Each implementation is expected to redefine the underlying method.

  81. abstract case class TypeRef(prefix: Type, name: TypeName) extends NamedType with Product with Serializable

  82. class TypeRefWithFixedSym extends TypeRef with WithFixedSym

  83. abstract class TypeTraverser extends TypeAccumulator[Unit]

  84. trait TypeType extends Type

    A marker trait for types that apply only to type symbols

  85. final class TypeVar extends CachedProxyType with ValueType

    In a TypeApply tree, a TypeVar is created for each argument type to be inferred.

    In a TypeApply tree, a TypeVar is created for each argument type to be inferred. Every type variable is referred to by exactly one inferred type parameter of some TypeApply tree.

    A type variable is essentially a switch that models some part of a substitution. It is first linked to origin, a poly param that's in the current constraint set. It can then be (once) instantiated to some other type. The instantiation is recorded in the type variable itself, or else, if the current type state is different from the variable's creation state (meaning unrolls are possible) in the current typer state.

  86. abstract class UncachedGroundType extends Type

    Instances of this class are uncached and are not proxies.

  87. abstract class UncachedProxyType extends TypeProxy

    Instances of this class are uncached and are proxies.

  88. trait ValueType extends Type with ValueTypeOrProto

    A marker trait for types that can be types of values or that are higher-kinded

  89. trait ValueTypeOrProto extends Type with TermType

    A marker trait for types that can be types of values or prototypes of value types

  90. abstract case class WildcardType(optBounds: Type) extends CachedGroundType with TermType with Product with Serializable

    Wildcard type, possibly with bounds

  91. trait WithFixedSym extends NamedType

Value Members

  1. final def !=(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  4. object AndType extends Serializable

  5. object AnnotatedType extends Serializable

  6. object ClassInfo extends Serializable

  7. object ConstantType extends Serializable

  8. object CyclicReference extends Serializable

  9. object ErrorType extends ErrorType

  10. object ExprType extends Serializable

  11. object HKApply extends Serializable

  12. object IdentityTypeMap extends TypeMap

    Annotations
    @sharable()
  13. object ImplicitMethodType extends MethodTypeCompanion with Serializable

  14. object JavaArrayType extends Serializable

  15. object JavaMethodType extends MethodTypeCompanion with Serializable

  16. object MethodParam extends Serializable

  17. object MethodType extends MethodTypeCompanion with Serializable

  18. object NamedType

  19. object NoPrefix extends CachedGroundType with Product with Serializable

    Missing prefix

    Missing prefix

    Annotations
    @sharable()
  20. object NoType extends CachedGroundType with Product with Serializable

    Sentinel for "missing type"

    Sentinel for "missing type"

    Annotations
    @sharable()
  21. object OrType extends Serializable

  22. object PolyType

  23. object RecType

  24. object RefinedType extends Serializable

  25. object SAMType

    An extractor for single abstract method types.

    An extractor for single abstract method types. A type is a SAM type if it is a reference to a class or trait, which

    • has a single abstract method with a method type (ExprType and PolyType not allowed!)
    • can be instantiated without arguments or with just () as argument.

    The pattern SAMType(denot) matches a SAM type, where denot is the denotation of the single abstract method as a member of the type.

  26. object SkolemType extends Serializable

  27. object SuperType extends Serializable

  28. object TermRef extends Serializable

  29. object ThisType extends Serializable

  30. object TryDynamicCallType extends ErrorType

  31. object TypeAlias extends Serializable

  32. object TypeBounds extends Serializable

  33. object TypeRef extends Serializable

  34. object WildcardType extends WildcardType

    Annotations
    @sharable()
  35. object abstractTermNameFilter extends NameFilter

    A filter for names of deferred term definitions of a given type

  36. object abstractTypeNameFilter extends NameFilter

    A filter for names of abstract types of a given type

  37. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  38. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  39. var debugTrace: Boolean

  40. implicit def decorateTypeApplications(tpe: Type): TypeApplications

  41. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  42. implicit def eqType: Eq[Type, Type]

  43. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  44. object fieldFilter extends NameFilter

  45. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  46. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  47. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  48. object implicitFilter extends NameFilter

  49. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  50. def isWatched(tp: Type): Boolean

  51. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  52. object nonClassTypeNameFilter extends NameFilter

    A filter for names of abstract types of a given type

  53. final def notify(): Unit

    Definition Classes
    AnyRef
  54. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  55. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  56. object takeAllFilter extends NameFilter

  57. def toString(): String

    Definition Classes
    AnyRef → Any
  58. object typeNameFilter extends NameFilter

  59. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  60. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  61. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  62. val watchList: List[TypeName]

Inherited from AnyRef

Inherited from Any

Ungrouped