scala.tools.nsc.symtab.Symbols

Symbol

abstract class Symbol extends AbsSymbol

The class for all symbols

Definition Classes
Symbols → Symbols
Source
Symbols.scala
Linear Supertypes
AbsSymbol, HasFlags, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Hide All
  2. Show all
  1. Symbol
  2. AbsSymbol
  3. HasFlags
  4. AnyRef
  5. Any
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Symbol(initOwner: Symbol, initPos: Position, initName: Name)

Type Members

  1. type AccessBoundaryType = Symbol

    Definition Classes
    AbsSymbol → HasFlags
  2. type AnnotationType = AnnotationInfo

    Definition Classes
    AbsSymbol → HasFlags
  3. type FlagsType = Long

    Definition Classes
    AbsSymbol → HasFlags

Abstract Value Members

  1. abstract def cloneSymbolImpl(owner: Symbol): Symbol

    Internal method to clone a symbol's implementation without flags or type

  2. abstract def doCookJavaRawInfo(): Unit

    Attributes
    protected

Concrete Value Members

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

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

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

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

    Definition Classes
    Any
  6. def accessBoundary(base: Symbol): Symbol

    The class or term up to which this symbol is accessible, or RootClass if it is public.

  7. final def accessed(ownerTp: Type): Symbol

    The symbol accessed by this accessor function, but with given owner type

  8. final def accessed: Symbol

    The symbol accessed by this accessor (getter or setter) function.

  9. final def accurateKindString: String

    Accurate string representation of symbols' kind, suitable for developers.

  10. def addAnnotation(annot: AnnotationInfo): Unit

    Definition Classes
    Symbol → AbsSymbol
  11. def addChild(sym: Symbol): Unit

    Definition Classes
    AbsSymbol
  12. def alias: Symbol

    For a paramaccessor: a superclass paramaccessor for which this symbol is an alias, NoSymbol for all others

  13. final def allOverriddenSymbols: List[Symbol]

    Returns all symbols overriden by this symbol

  14. def alternatives: List[Symbol]

  15. def ancestors: List[Symbol]

    All directly or indirectly inherited classes.

  16. def annotations: List[AnnotationInfo]

    After the typer phase (before, look at the definition's Modifiers), contains the annotations attached to member a definition (class, method, type, field).

    After the typer phase (before, look at the definition's Modifiers), contains the annotations attached to member a definition (class, method, type, field).

    Definition Classes
    Symbol → HasFlags
  17. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  18. final def caseFieldAccessors: List[Symbol]

    Return every accessor of a primary constructor parameter in this case class.

    Return every accessor of a primary constructor parameter in this case class. The scope declarations may be out of order because fields with less than private access are first given a regular getter, then a new renamed getter which comes later in the declaration list. For this reason we have to pinpoint the right accessors by starting with the original fields (which will be in the right order) and looking for getters with applicable names. The getters may have the standard name "foo" or may have been renamed to "foo$\d+" in SyntheticMethods. See ticket #1373.

  19. final def caseModule: Symbol

    The case module corresponding to this case class

  20. def children: List[Symbol]

    If this is a sealed class, its known direct subclasses.

    If this is a sealed class, its known direct subclasses. Otherwise Set.empty

  21. def classBound: Type

    The least proper supertype of a class; includes all parent types and refinement where needed.

    The least proper supertype of a class; includes all parent types and refinement where needed. You need to compute that in a situation like this: { class C extends P { ... } new C }

  22. def clone(): AnyRef

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  23. final def cloneSymbol(owner: Symbol): Symbol

    A clone of this symbol, but with given owner

  24. final def cloneSymbol: Symbol

    A clone of this symbol

  25. final def companionClass: Symbol

    For a module or case factory: the class with the same name in the same package.

    For a module or case factory: the class with the same name in the same package. For all others: NoSymbol Note: does not work for classes owned by methods, see Namers.companionClassOf

    object Foo . companionClass --> class Foo

  26. final def companionModule: Symbol

    For a class: the module or case class factory with the same name in the same package.

    For a class: the module or case class factory with the same name in the same package. For all others: NoSymbol Note: does not work for modules owned by methods, see Namers.companionModuleOf

    class Foo . companionModule --> object Foo

  27. final def companionSymbol: Symbol

    For a module: its linked class For a plain class: its linked module or case factory.

    For a module: its linked class For a plain class: its linked module or case factory. Note: does not work for modules owned by methods, see Namers.companionSymbolOf

    class Foo <-- companionSymbol --> object Foo

  28. final def constrParamAccessors: List[Symbol]

  29. final def cookJavaRawInfo(): Unit

    Modify term symbol's type so that a raw type C is converted to an existential C[_]

    Modify term symbol's type so that a raw type C is converted to an existential C[_]

    This is done in checkAccessible and overriding checks in refchecks We can't do this on class loading because it would result in infinite cycles.

  30. def deSkolemize: Symbol

    If this symbol is a type parameter skolem (not an existential skolem!) its corresponding type parameter, otherwise this

  31. def decodedName: String

    Definition Classes
    AbsSymbol
  32. def defString: String

    String representation of symbol's definition

  33. def defaultFlagMask: Long

  34. def defaultFlagString: String

  35. final def definedInPackage: Boolean

  36. def deprecationMessage: Option[String]

  37. def deprecationVersion: Option[String]

  38. def elisionLevel: Option[Int]

  39. def enclClass: Symbol

    Definition Classes
    AbsSymbol
  40. def enclClassChain: List[Symbol]

  41. def enclMethod: Symbol

    Definition Classes
    AbsSymbol
  42. def enclosingPackage: Symbol

    The package containing this symbol, or NoSymbol if there is not one.

  43. def enclosingPackageClass: Symbol

    The package class containing this symbol, or NoSymbol if there is not one.

  44. def encodedName: String

    Definition Classes
    AbsSymbol
  45. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  46. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  47. def existentialBound: Type

    If we quantify existentially over this symbol, the bound of the type variable that stands for it pre: symbol is a term, a class, or an abstract type (no alias type allowed)

  48. def existentialToString: String

    String representation of existentially bound variable

  49. final def exists: Boolean

  50. def expandName(base: Symbol): Unit

    change name by appending $$<fully-qualified-name-of-class base'> Do the same for any accessed symbols or setters/getters

  51. final def extendedOverriddenSymbols: List[Symbol]

    Returns all symbols overridden by this symbol, plus all matching symbols defined in parents of the selftype

  52. def filter(cond: (Symbol) ⇒ Boolean): Symbol

  53. def finalize(): Unit

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  54. final def flags: Long

    Definition Classes
    Symbol → AbsSymbol → HasFlags
  55. final def flags_=(fs: Long): Unit

    Definition Classes
    Symbol → AbsSymbol
  56. final def freshExistential(suffix: String): Symbol

  57. def fullLocationString: String

  58. final def fullName: String

    Definition Classes
    AbsSymbol
  59. final def fullName(separator: Char): String

    Definition Classes
    AbsSymbol
  60. def getAnnotation(cls: Symbol): Option[AnnotationInfo]

  61. final def getClass(): java.lang.Class[_]

    Definition Classes
    AnyRef → Any
  62. final def getFlag(mask: Long): Long

  63. final def getter(base: Symbol): Symbol

    The getter of this value or setter definition in class base', or NoSymbol if none exists.

  64. def hasAbstractFlag: Boolean

    Definition Classes
    HasFlags
  65. final def hasAccessBoundary: Boolean

    Definition Classes
    AbsSymbol → HasFlags
  66. def hasAccessorFlag: Boolean

    Definition Classes
    HasFlags
  67. final def hasAllFlags(mask: Long): Boolean

    Definition Classes
    AbsSymbol → HasFlags
  68. def hasAnnotation(cls: Symbol): Boolean

    Does this symbol have an annotation of the given class?

  69. def hasAssignedAnnotations: Boolean

  70. def hasBridgeAnnotation: Boolean

  71. def hasContravariantFlag: Boolean

    Definition Classes
    HasFlags
  72. def hasDefault: Boolean

    Definition Classes
    HasFlags
  73. def hasDefaultFlag: Boolean

    Definition Classes
    HasFlags
  74. final def hasFlag(mask: Long): Boolean

    Definition Classes
    AbsSymbol → HasFlags
  75. def hasFlagsToString(mask: Long): String

    Definition Classes
    Symbol → HasFlags
  76. final def hasGetter: Boolean

  77. def hasInConstructorFlag: Boolean

    Definition Classes
    HasFlags
  78. def hasLocalFlag: Boolean

    Definition Classes
    HasFlags
  79. def hasMeaninglessName: Boolean

    If the name of the symbol's owner should be used when you care about seeing an interesting name: in such cases this symbol is e.

    If the name of the symbol's owner should be used when you care about seeing an interesting name: in such cases this symbol is e.g. a method parameter with a synthetic name, a constructor named "this", an object "package", etc. The kind string, if non-empty, will be phrased relative to the name of the owner.

  80. def hasMigrationAnnotation: Boolean

  81. def hasModuleFlag: Boolean

    Definition Classes
    HasFlags
  82. def hasNoFlags(mask: Long): Boolean

    Definition Classes
    HasFlags
  83. def hasPackageFlag: Boolean

    Definition Classes
    HasFlags
  84. def hasParamWhich(cond: (Symbol) ⇒ Boolean): Boolean

  85. def hasPreSuperFlag: Boolean

    Definition Classes
    HasFlags
  86. def hasRawInfo: Boolean

  87. def hasStableFlag: Boolean

    Definition Classes
    HasFlags
  88. def hasStaticFlag: Boolean

    Definition Classes
    HasFlags
  89. def hasTraitFlag: Boolean

    Definition Classes
    HasFlags
  90. def hasTransOwner(sym: Symbol): Boolean

    same as ownerChain contains sym, but more efficient, and with a twist for refinement classes.

    same as ownerChain contains sym, but more efficient, and with a twist for refinement classes. A refinement class has a transowner X if an of its parents has transowner X.

  91. final def hasTypeAt(pid: Int): Boolean

    Was symbol's type updated during given phase?

  92. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  93. val id: Int

  94. final def idString: String

    If settings.

    If settings.uniqid is set, the symbol's id, else ""

  95. final def implClass: Symbol

    The implementation class of a trait

  96. def implicitNotFoundMsg: Option[String]

  97. def inDefaultNamespace: Boolean

  98. def info: Type

    Get type info associated with symbol at current phase, after ensuring that symbol is initialized (i.

    Get type info associated with symbol at current phase, after ensuring that symbol is initialized (i.e. type is completed).

    Definition Classes
    Symbol → AbsSymbol
  99. final def infoString(tp: Type): String

    String representation of symbol's definition following its name

  100. def info_=(info: Type): Unit

    Definition Classes
    Symbol → AbsSymbol
  101. def infosString: String

  102. final def initialize: Symbol.this.type

    Initialize the symbol

  103. final def isAbstractClass: Boolean

    Definition Classes
    AbsSymbol
  104. def isAbstractOverride: Boolean

    Definition Classes
    HasFlags
  105. def isAbstractType: Boolean

    Definition Classes
    AbsSymbol
  106. def isAliasType: Boolean

    Definition Classes
    AbsSymbol
  107. final def isAnonOrRefinementClass: Boolean

  108. final def isAnonymousClass: Boolean

  109. final def isAnonymousFunction: Boolean

  110. final def isAuxiliaryConstructor: Boolean

    Does this symbol denote an auxiliary constructor of its enclosing class?

  111. final def isBridge: Boolean

    Definition Classes
    AbsSymbol
  112. def isByNameParam: Boolean

    Definition Classes
    HasFlags
  113. final def isCapturedVariable: Boolean

  114. def isCase: Boolean

    Definition Classes
    HasFlags
  115. def isCaseAccessor: Boolean

    Definition Classes
    HasFlags
  116. final def isCaseApplyOrUnapply: Boolean

    Is this symbol a synthetic apply or unapply method in a companion object of a case class?

  117. def isCaseClass: Boolean

  118. def isClass: Boolean

    Definition Classes
    AbsSymbol
  119. final def isClassConstructor: Boolean

  120. final def isClassLocalToConstructor: Boolean

  121. def isCoDefinedWith(that: Symbol): Boolean

    Is this symbol defined in the same scope and compilation unit as that' symbol?

  122. final def isConstant: Boolean

    Is this symbol a constant?

  123. final def isConstructor: Boolean

  124. final def isContravariant: Boolean

    Definition Classes
    AbsSymbol
  125. final def isCovariant: Boolean

    Definition Classes
    AbsSymbol
  126. def isDefaultInit: Boolean

    Definition Classes
    HasFlags
  127. def isDeferred: Boolean

    Definition Classes
    HasFlags
  128. def isDeprecated: Boolean

  129. final def isEarlyInitialized: Boolean

    Definition Classes
    AbsSymbol
  130. def isEffectiveRoot: Boolean

    Definition Classes
    AbsSymbol
  131. final def isEffectivelyFinal: Boolean

    Is this symbol effectively final? I.

    Is this symbol effectively final? I.e, it cannot be overridden

  132. final def isEmptyPackage: Boolean

    Definition Classes
    AbsSymbol
  133. final def isEmptyPackageClass: Boolean

    Definition Classes
    AbsSymbol
  134. final def isErroneous: Boolean

  135. final def isError: Boolean

  136. final def isExistentialQuantified: Boolean

  137. final def isExistentialSkolem: Boolean

  138. final def isExistentiallyBound: Boolean

    Definition Classes
    AbsSymbol
  139. def isFinal: Boolean

    Definition Classes
    HasFlags
  140. final def isGetter: Boolean

  141. final def isHigherOrderTypeParameter: Boolean

  142. final def isImplClass: Boolean

    Definition Classes
    AbsSymbol
  143. final def isImplOnly: Boolean

    Is this a symbol which exists only in the implementation class, not in its trait?

  144. def isImplicit: Boolean

    Definition Classes
    HasFlags
  145. final def isIncompleteIn(base: Symbol): Boolean

    A a member of class base' is incomplete if (1) it is declared deferred or (2) it is abstract override and its super symbol in base' is nonexistent or incomplete.

    A a member of class base' is incomplete if (1) it is declared deferred or (2) it is abstract override and its super symbol in base' is nonexistent or incomplete.

    base

    ...

    returns

    ...

  146. final def isInitialized: Boolean

  147. final def isInitializedToDefault: Boolean

  148. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  149. def isInterface: Boolean

    Definition Classes
    HasFlags
  150. final def isInterpreterWrapper: Boolean

    Does this symbol denote a wrapper object of the interpreter or its class?

  151. def isJavaDefined: Boolean

    Definition Classes
    HasFlags
  152. final def isJavaInterface: Boolean

  153. def isLabel: Boolean

    Definition Classes
    HasFlags
  154. def isLazy: Boolean

    Definition Classes
    HasFlags
  155. final def isLazyAccessor: Boolean

    Definition Classes
    AbsSymbol
  156. final def isLess(that: Symbol): Boolean

    A total ordering between symbols that refines the class inheritance graph (i.

    A total ordering between symbols that refines the class inheritance graph (i.e. subclass.isLess(superclass) always holds). the ordering is given by: (_.isType, -_.baseTypeSeq.length) for type symbols, followed by id'.

  157. def isLessAccessibleThan(other: Symbol): Boolean

  158. def isLifted: Boolean

    Definition Classes
    HasFlags
  159. def isLiftedMethod: Boolean

  160. final def isLocal: Boolean

    Is this symbol locally defined? I.

    Is this symbol locally defined? I.e. not accessed from outside this' instance

  161. final def isLocalClass: Boolean

    Is this class locally defined? A class is local, if

    Is this class locally defined? A class is local, if

    • it is anonymous, or
    • its owner is a value
    • it is defined within a local class
  162. final def isLocalDummy: Boolean

  163. def isMemberOf(clazz: Symbol): Boolean

    Is this symbol a member of class clazz'

  164. final def isMethod: Boolean

    Definition Classes
    AbsSymbol
  165. final def isMixinConstructor: Boolean

  166. final def isModule: Boolean

    Definition Classes
    AbsSymbol
  167. final def isModuleClass: Boolean

    Definition Classes
    AbsSymbol
  168. final def isModuleVar: Boolean

    Is this symbol a module variable? This used to have to test for MUTABLE to distinguish the overloaded MODULEVAR/SYNTHETICMETH flag, but now SYNTHETICMETH is gone.

  169. final def isMonomorphicType: Boolean

    Is symbol a monomorphic type? assumption: if a type starts out as monomorphic, it will not acquire type parameters in later phases.

  170. def isMutable: Boolean

    Definition Classes
    HasFlags
  171. final def isNestedClass: Boolean

    Is this class nested in another class or module (not a package)?

  172. final def isNestedIn(that: Symbol): Boolean

    A partial ordering between symbols.

    A partial ordering between symbols. (this isNestedIn that) holds iff this symbol is defined within a class or method defining that symbol

  173. final def isNonBottomSubClass(that: Symbol): Boolean

    Is this class symbol a subclass of that symbol?

  174. def isNonClassType: Boolean

    Is this symbol a type but not a class?

  175. final def isNumericSubClass(that: Symbol): Boolean

  176. final def isOuterAccessor: Boolean

    Is this symbol an accessor method for outer?

  177. final def isOuterField: Boolean

    Is this symbol an accessor method for outer?

  178. final def isOverloaded: Boolean

    Definition Classes
    AbsSymbol
  179. def isOverride: Boolean

    Definition Classes
    HasFlags
  180. final def isPackage: Boolean

    Definition Classes
    AbsSymbol
  181. final def isPackageClass: Boolean

    Definition Classes
    AbsSymbol
  182. final def isPackageObject: Boolean

  183. final def isPackageObjectClass: Boolean

  184. def isParamAccessor: Boolean

    Definition Classes
    HasFlags
  185. def isParameter: Boolean

    Definition Classes
    HasFlags
  186. final def isPredefModule: Boolean

  187. final def isPrimaryConstructor: Boolean

    Does this symbol denote the primary constructor of its enclosing class?

  188. def isPrivate: Boolean

    Definition Classes
    HasFlags
  189. def isPrivateLocal: Boolean

    Definition Classes
    HasFlags
  190. def isProtected: Boolean

    Definition Classes
    HasFlags
  191. def isProtectedLocal: Boolean

    Definition Classes
    HasFlags
  192. def isPublic: Boolean

    Definition Classes
    HasFlags
  193. final def isRefinementClass: Boolean

    Definition Classes
    AbsSymbol
  194. final def isRoot: Boolean

    Definition Classes
    AbsSymbol
  195. final def isRootPackage: Boolean

    Definition Classes
    AbsSymbol
  196. final def isScalaPackage: Boolean

  197. final def isScalaPackageClass: Boolean

  198. def isSealed: Boolean

    Definition Classes
    HasFlags
  199. def isSerializable: Boolean

  200. final def isSetter: Boolean

  201. def isSetterParameter: Boolean

  202. def isSingletonExistential: Boolean

  203. final def isSourceMethod: Boolean

    Definition Classes
    AbsSymbol
  204. final def isStable: Boolean

    Does this symbol denote a stable value?

  205. final def isStableClass: Boolean

  206. final def isStatic: Boolean

    Is this symbol static (i.

    Is this symbol static (i.e. with no outer instance)?

  207. final def isStaticConstructor: Boolean

    Is this symbol a static constructor?

  208. final def isStaticMember: Boolean

    Is this symbol a static member of its class? (i.

    Is this symbol a static member of its class? (i.e. needs to be implemented as a Java static?)

  209. final def isStaticModule: Boolean

  210. final def isStaticOwner: Boolean

    Does this symbol denote a class that defines static symbols?

  211. def isStrictFP: Boolean

  212. final def isStructuralRefinement: Boolean

    Is this class or type defined as a structural refinement type?

  213. final def isSubClass(that: Symbol): Boolean

  214. def isSuperAccessor: Boolean

    Definition Classes
    HasFlags
  215. def isSynthetic: Boolean

    Definition Classes
    HasFlags
  216. def isTerm: Boolean

    Definition Classes
    AbsSymbol
  217. final def isThisSym: Boolean

  218. final def isTrait: Boolean

    Definition Classes
    Symbol → AbsSymbol → HasFlags
  219. def isType: Boolean

    Definition Classes
    AbsSymbol
  220. final def isTypeParameter: Boolean

    Definition Classes
    AbsSymbol
  221. final def isTypeParameterOrSkolem: Boolean

  222. final def isTypeSkolem: Boolean

  223. final def isUpdatedAt(pid: Int): Boolean

    Was symbol's type updated during given phase?

  224. final def isValue: Boolean

    Term symbols with the exception of static parts of Java classes and packages.

  225. final def isValueParameter: Boolean

  226. final def isVarargsMethod: Boolean

    Definition Classes
    AbsSymbol
  227. final def isVariable: Boolean

  228. def isVirtualClass: Boolean

  229. def isVirtualTrait: Boolean

  230. final def keyString: String

    String representation of symbol's definition key word

  231. final def kindString: String

  232. def lazyAccessor: Symbol

    For a lazy value, its lazy accessor.

    For a lazy value, its lazy accessor. NoSymbol for all others

    Definition Classes
    Symbol → AbsSymbol
  233. def lazyAccessorOrSelf: Symbol

    If this is a lazy value, the lazy accessor; otherwise this symbol.

  234. final def linkedClassOfClass: Symbol

    For a module class: its linked class For a plain class: the module class of its linked module.

    For a module class: its linked class For a plain class: the module class of its linked module.

    class Foo <-- linkedClassOfClass --> class Foo$

    Definition Classes
    Symbol → AbsSymbol
  235. def locationString: String

    String representation of location, plus a preposition.

    String representation of location, plus a preposition. Doesn't do much, for backward compatibility reasons.

  236. def lock(handler: ⇒ Unit): Unit

  237. def lockOK: Boolean

  238. def logicallyEnclosingMember: Symbol

    The method or class which logically encloses the current symbol.

    The method or class which logically encloses the current symbol. If the symbol is defined in the initialization part of a template this is the template's primary constructor, otherwise it is the physically enclosing method or class.

    Example 1:

    def f() { val x = { def g() = ...; g() } }

    In this case the owner chain of g' is x', followed by f' and g.logicallyEnclosingMember == f.

    Example 2:

    class C { def <init> = { ... } val x = { def g() = ...; g() } } }

    In this case the owner chain of g' is x', followed by C' but g.logicallyEnclosingMember is the primary constructor symbol <init>' (or, for traits: $init') of C'.

  239. final def makeNotPrivate(base: Symbol): Unit

    Remove private modifier from symbol sym's definition. If sym' is a term symbol rename it by expanding its name to avoid name clashes

  240. def makeSerializable(): Unit

    Adds the interface scala.

    Adds the interface scala.Serializable to the parents of a ClassInfoType. Note that the tree also has to be updated accordingly.

  241. final def matchingSymbol(site: Type, admit: Long = 0L): Symbol

    The non-private member of site' whose type and name match the type of this symbol

  242. final def matchingSymbol(ofclazz: Symbol, site: Type): Symbol

    The non-private symbol whose type matches the type of this symbol in in given class.

    The non-private symbol whose type matches the type of this symbol in in given class.

    ofclazz

    The class containing the symbol's definition

    site

    The base type from which member types are computed

  243. def migrationMessage: Option[String]

  244. def migrationVersion: Option[String]

  245. def mixinClasses: List[Symbol]

    The directly or indirectly inherited mixins of this class except for mixin classes inherited by the superclass.

    The directly or indirectly inherited mixins of this class except for mixin classes inherited by the superclass. Mixin classes appear in linearization order.

  246. def moduleClass: Symbol

    The module class corresponding to this module.

    The module class corresponding to this module.

    Definition Classes
    Symbol → AbsSymbol
  247. def name: Name

    Definition Classes
    Symbol → AbsSymbol
  248. def nameString: String

    String representation of symbol's simple name.

    String representation of symbol's simple name. If !settings.debug translates expansions of operators back to operator symbol. E.g. $eq => =. If settings.uniqid, adds id.

  249. final def name_=(name: Name): Unit

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

    Definition Classes
    AnyRef
  251. final def needsFlatClasses: Boolean

  252. final def needsImplClass: Boolean

    Is this symbol a trait which needs an implementation class?

  253. final def newAbstractType(name: TypeName, pos: Position = NoPosition): TypeSymbol

    Definition Classes
    Symbol → AbsSymbol
  254. final def newAbstractType(pos: Position, name: TypeName): TypeSymbol

    Symbol of an abstract type type T >: .

    Symbol of an abstract type type T >: ... <: ...

  255. final def newAliasType(name: TypeName, pos: Position = NoPosition): TypeSymbol

    Definition Classes
    Symbol → AbsSymbol
  256. final def newAliasType(pos: Position, name: TypeName): TypeSymbol

    Symbol of a type definition type T = .

    Symbol of a type definition type T = ...

  257. final def newAnonymousClass(pos: Position): ClassSymbol

  258. final def newAnonymousFunctionClass(pos: Position): ClassSymbol

  259. final def newClass(name: TypeName, pos: Position = NoPosition): ClassSymbol

    Definition Classes
    Symbol → AbsSymbol
  260. final def newClass(pos: Position, name: TypeName): ClassSymbol

  261. final def newConstructor(pos: Position): MethodSymbol

  262. final def newErrorClass(name: TypeName): ClassSymbol

  263. final def newErrorSymbol(name: Name): Symbol

  264. final def newErrorValue(name: TermName): TermSymbol

  265. final def newExistential(pos: Position, name: TypeName): Symbol

  266. final def newGetter: Symbol

    Create a new getter for current symbol (which must be a field)

  267. final def newImport(pos: Position): TermSymbol

  268. final def newLabel(pos: Position, name: TermName): MethodSymbol

  269. final def newLocalDummy(pos: Position): TermSymbol

    Create local dummy for template (owner of local blocks)

  270. final def newMethod(name: TermName, pos: Position = NoPosition): MethodSymbol

    Definition Classes
    Symbol → AbsSymbol
  271. final def newMethod(pos: Position, name: TermName): MethodSymbol

  272. final def newModule(pos: Position, name: TermName): TermSymbol

  273. final def newModule(name: TermName, clazz: Symbol, pos: Position = NoPosition): TermSymbol

    Definition Classes
    Symbol → AbsSymbol
  274. final def newModule(pos: Position, name: TermName, clazz: ClassSymbol): TermSymbol

  275. final def newModuleClass(name: TypeName, pos: Position = NoPosition): ModuleClassSymbol

    Definition Classes
    Symbol → AbsSymbol
  276. final def newModuleClass(pos: Position, name: TypeName): ModuleClassSymbol

  277. final def newOuterAccessor(pos: Position): MethodSymbol

    for explicit outer phase

  278. final def newOverloaded(pre: Type, alternatives: List[Symbol]): Symbol

    pre

    type relative to which alternatives are seen. for instance: class C[T] { def m(x: T): T def m'(): T } val v: C[Int]

    Then v.m has symbol TermSymbol(flags = {OVERLOADED}, tpe = OverloadedType(C[Int], List(m, m'))) You recover the type of m doing a

    m.tpe.asSeenFrom(pre, C) (generally, owner of m, which is C here).

    or:

    pre.memberType(m)

  279. final def newPackage(pos: Position, name: TermName): TermSymbol

  280. final def newRefinementClass(pos: Position): ClassSymbol

    Refinement types P { val x: String; type T <: Number } also have symbols, they are refinementClasses

  281. final def newSyntheticValueParam(argtype: Type): Symbol

    Synthetic value parameter when parameter symbol is not available.

    Synthetic value parameter when parameter symbol is not available. Calling this method multiple times will re-use the same parameter name.

  282. final def newSyntheticValueParams(argtypes: List[Type]): List[Symbol]

    Synthetic value parameters when parameter symbols are not available.

    Synthetic value parameters when parameter symbols are not available. Calling this method multiple times will re-use the same parameter names.

  283. final def newSyntheticValueParamss(argtypess: List[List[Type]]): List[List[Symbol]]

    Synthetic value parameters when parameter symbols are not available

  284. final def newThisSym(pos: Position): TermSymbol

  285. final def newTypeParameter(pos: Position, name: TypeName): TypeSymbol

    Symbol of a type parameter

  286. final def newTypeSkolem: Symbol

    Type skolems are type parameters seen from the inside Assuming a polymorphic method m[T], its type is a PolyType which has a TypeParameter with name T' in its typeParams list. While type checking the parameters, result type and body of the method, there's a local copy of T' which is a TypeSkolem.

  287. final def newValue(name: TermName, pos: Position = NoPosition): TermSymbol

    Definition Classes
    Symbol → AbsSymbol
  288. final def newValue(pos: Position, name: TermName): TermSymbol

  289. final def newValueParameter(pos: Position, name: TermName): TermSymbol

  290. final def newVariable(pos: Position, name: TermName): TermSymbol

  291. final def notify(): Unit

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

    Definition Classes
    AnyRef
  293. def orElse[T](alt: ⇒ Symbol): Symbol

    Definition Classes
    AbsSymbol
  294. def originalEnclosingMethod: Symbol

    Return the original enclosing method of this symbol.

    Return the original enclosing method of this symbol. It should return the same thing as enclMethod when called before lambda lift, but it preserves the original nesting when called afterwards.

  295. def originalName: Name

    If this symbol has an expanded name, its original name, otherwise its name itself.

    If this symbol has an expanded name, its original name, otherwise its name itself.

    See also

    expandName

  296. final def outerClass: Symbol

    The class that is logically an outer class of given clazz'. This is the enclosing class, except for classes defined locally to constructors, where it is the outer class of the enclosing class

  297. def outerSource: Symbol

    For an outer accessor: The class from which the outer originates.

    For an outer accessor: The class from which the outer originates. For all other symbols: NoSymbol

  298. final def overriddenSymbol(ofclazz: Symbol): Symbol

    The symbol overridden by this symbol in given class ofclazz'.

  299. final def overridingSymbol(ofclazz: Symbol): Symbol

    The symbol overriding this symbol in given subclass ofclazz'

  300. def owner: Symbol

    Definition Classes
    Symbol → AbsSymbol
  301. def ownerChain: List[Symbol]

  302. final def owner_=(owner: Symbol): Unit

    Definition Classes
    Symbol → AbsSymbol
  303. def ownersIterator: Iterator[Symbol]

  304. def ownsString: String

    String representation of location.

  305. def paramss: List[List[Symbol]]

    The value parameter sections of this symbol.

  306. def pos: Position

  307. def primaryConstructor: Symbol

    The primary constructor of a class

  308. final def printWithoutPrefix: Boolean

    Conditions where we omit the prefix when printing a symbol, to avoid unpleasantries like Predef.

    Conditions where we omit the prefix when printing a symbol, to avoid unpleasantries like Predef.String, $iw.$iw.Foo and <empty>.Bippy.

  309. def privateWithin: Symbol

    Definition Classes
    Symbol → AbsSymbol → HasFlags
  310. def privateWithin_=(sym: Symbol): Unit

    Definition Classes
    Symbol → AbsSymbol
  311. def rawAnnotations: List[AnnotationInfoBase]

  312. def rawInfo: Type

    Return info without checking for initialization or completing

    Return info without checking for initialization or completing

    Definition Classes
    Symbol → AbsSymbol
  313. var rawflags: Long

  314. var rawname: Name

  315. var rawowner: Symbol

  316. def removeAnnotation(cls: Symbol): Unit

    Remove all annotations matching the given class.

  317. def reset(completer: Type): Unit

    Reset symbol to initial state

  318. final def resetFlag(mask: Long): Symbol.this.type

  319. final def resetFlags(): Unit

  320. def sealedDescendants: List[Symbol]

    Recursively finds all sealed descendants and returns a sorted list.

    Recursively finds all sealed descendants and returns a sorted list. Includes this symbol unless it is abstract, but as value classes are marked abstract so they can't be instantiated, they are special cased.

  321. final def sealedSortName: String

    The String used to order otherwise identical sealed symbols.

    The String used to order otherwise identical sealed symbols. This uses data which is stable across runs and variable classpaths (the initial Name) before falling back on id, which varies depending on exactly when a symbol is loaded.

  322. def setAnnotations(annots: List[AnnotationInfoBase]): Symbol.this.type

  323. final def setFlag(mask: Long): Symbol.this.type

  324. def setInfo(info: Type): Symbol.this.type

    Set initial info.

  325. def setInfoOwnerAdjusted(info: Type): Symbol.this.type

  326. def setPos(pos: Position): Symbol.this.type

  327. final def setter(base: Symbol, hasExpandedName: Boolean): Symbol

  328. final def setter(base: Symbol): Symbol

    The setter of this value or getter definition, or NoSymbol if none exists

  329. final def simpleName: Name

    The simple name of this Symbol

  330. final def skipConstructor: Symbol

    If this is a constructor, its owner: otherwise this.

  331. final def skipPackageObject: Symbol

    If this is a package object or package object class, its owner: otherwise this.

  332. def sourceFile: AbstractFile

  333. def sourceFile_=(f: AbstractFile): Unit

  334. def sourceModule: Symbol

    Definition Classes
    AbsSymbol
  335. def sourceModule_=(sym: Symbol): Unit

    Definition Classes
    AbsSymbol
  336. def suchThat(cond: (Symbol) ⇒ Boolean): Symbol

  337. def superClass: Symbol

    The superclass of this class

  338. final def superSymbol(base: Symbol): Symbol

    The symbol accessed by a super in the definition of this symbol when seen from class base'. This symbol is always concrete. pre: this.

    The symbol accessed by a super in the definition of this symbol when seen from class base'. This symbol is always concrete. pre: this.owner' is in the base class sequence of base'.

  339. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  340. final def tag: Int

    A tag which (in the ideal case) uniquely identifies class symbols

  341. def thisSym: Symbol

    The self symbol of a class with explicit self type, or else the symbol itself.

  342. def thisType: Type

    If symbol is a class, the type this.type in this class, otherwise NoPrefix.

    If symbol is a class, the type this.type in this class, otherwise NoPrefix. We always have: thisType <:< typeOfThis

  343. final def toInterface: Symbol

    If this symbol is an implementation class, its interface, otherwise the symbol itself The method follows two strategies to determine the interface.

    If this symbol is an implementation class, its interface, otherwise the symbol itself The method follows two strategies to determine the interface.

    • during or after erasure, it takes the last parent of the implementation class (which is always the interface, by convention)
    • before erasure, it looks up the interface name in the scope of the owner of the class. This only works for implementation classes owned by other classes or traits.
  344. def toString(): String

    String representation, including symbol's kind e.

    String representation, including symbol's kind e.g., "class Foo", "method Bar". If hasMeaninglessName is true, uses the owner's name to disambiguate identity.

    Definition Classes
    Symbol → AnyRef → Any
  345. def toplevelClass: Symbol

    The top-level class containing this symbol

  346. def tpe: Type

    Get type.

    Get type. The type of a symbol is: for a type symbol, the type corresponding to the symbol itself,

    Definition Classes
    Symbol → AbsSymbol
  347. def tpeHK: Type

  348. def typeConstructor: Type

    The type constructor of a symbol is: For a type symbol, the type corresponding to the symbol itself, excluding parameters.

    The type constructor of a symbol is: For a type symbol, the type corresponding to the symbol itself, excluding parameters. Not applicable for term symbols.

  349. def typeOfThis: Type

    The type of this' in a class, or else the type of the symbol itself.

    The type of this' in a class, or else the type of the symbol itself.

    Definition Classes
    Symbol → AbsSymbol
  350. def typeOfThis_=(tp: Type): Unit

    Definition Classes
    AbsSymbol
  351. def typeParams: List[Symbol]

    The type parameters of this symbol.

    The type parameters of this symbol. assumption: if a type starts out as monomorphic, it will not acquire type parameters later.

  352. def unlock(): Unit

  353. def unpackLocation: AnyRef

    If this symbol is an existential skolem the location (a Tree or null) where it was unpacked.

    If this symbol is an existential skolem the location (a Tree or null) where it was unpacked. Resulttype is AnyRef because trees are not visible here.

  354. def unsafeTypeParams: List[Symbol]

    The type parameters of this symbol, without ensuring type completion.

    The type parameters of this symbol, without ensuring type completion. assumption: if a type starts out as monomorphic, it will not acquire type parameters later.

  355. final def updateInfo(info: Type): Symbol

    Set new info valid from start of this phase.

  356. var validTo: Period

  357. final def variance: Int

    The variance of this symbol as an integer

  358. def varianceString: String

    String representation of symbol's variance

  359. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws()

Deprecated Value Members

  1. def isAbstract: Boolean

    Definition Classes
    HasFlags
    Annotations
    @deprecated
    Deprecated

    (Since version 2.9.0)

Inherited from AbsSymbol

Inherited from HasFlags

Inherited from AnyRef

Inherited from Any