scala.tools.nsc.ast.parser

TreeBuilder

abstract class TreeBuilder extends AnyRef

Methods for building trees, used in the parser. All the trees returned by this class must be untyped.

Source
TreeBuilder.scala
Linear Supertypes
AnyRef, Any
Known Subclasses
Type Hierarchy Learn more about scaladoc diagrams
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. TreeBuilder
  2. AnyRef
  3. Any
Implicitly
  1. by any2stringadd
  2. by any2stringfmt
  3. by any2ArrowAssoc
  4. by any2Ensuring
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new TreeBuilder()

Type Members

  1. abstract class Enumerator extends AnyRef

  2. case class Filter(pos: Global.Position, test: Global.Tree) extends Enumerator with Product with Serializable

  3. class GetVarTraverser extends Global.Traverser

    Traverse pattern and collect all variable names with their types in buffer The variables keep their positions; whereas the pattern is converted to be synthetic for all nodes that contain a variable position.

  4. case class ValEq(pos: Global.Position, pat: Global.Tree, rhs: Global.Tree) extends Enumerator with Product with Serializable

  5. case class ValFrom(pos: Global.Position, pat: Global.Tree, rhs: Global.Tree) extends Enumerator with Product with Serializable

Abstract Value Members

  1. abstract def freshName(prefix: String): Global.Name

  2. abstract def freshTermName(prefix: String): Global.TermName

  3. abstract def freshTypeName(prefix: String): Global.TypeName

  4. abstract val global: Global

  5. abstract def o2p(offset: Int): Global.Position

  6. abstract def r2p(start: Int, point: Int, end: Int): Global.Position

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. def +(other: String): String

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to StringAdd performed by method any2stringadd in scala.Predef.
    Definition Classes
    StringAdd
  5. def ->[B](y: B): (TreeBuilder, B)

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to ArrowAssoc[TreeBuilder] performed by method any2ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc
    Annotations
    @inline()
  6. final def ==(arg0: AnyRef): Boolean

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

    Definition Classes
    Any
  8. def addEvidenceParams(owner: Global.Name, vparamss: List[List[Global.ValDef]], contextBounds: List[Global.Tree]): List[List[Global.ValDef]]

    Append implicit parameter section if contextBounds nonempty

  9. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  10. def byNameApplication(tpe: Global.Tree): Global.Tree

  11. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  12. def convertToTypeName(t: Global.Tree): Option[Global.RefTree]

  13. def ensuring(cond: (TreeBuilder) ⇒ Boolean, msg: ⇒ Any): TreeBuilder

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to Ensuring[TreeBuilder] performed by method any2Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  14. def ensuring(cond: (TreeBuilder) ⇒ Boolean): TreeBuilder

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to Ensuring[TreeBuilder] performed by method any2Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  15. def ensuring(cond: Boolean, msg: ⇒ Any): TreeBuilder

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to Ensuring[TreeBuilder] performed by method any2Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  16. def ensuring(cond: Boolean): TreeBuilder

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to Ensuring[TreeBuilder] performed by method any2Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  17. final def eq(arg0: AnyRef): Boolean

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

    Definition Classes
    AnyRef → Any
  19. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  20. def formatted(fmtstr: String): String

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to StringFormat performed by method any2stringfmt in scala.Predef.
    Definition Classes
    StringFormat
    Annotations
    @inline()
  21. def freshName(): Global.Name

  22. def freshTermName(): Global.TermName

  23. final def getClass(): Class[_]

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

    Definition Classes
    AnyRef → Any
  25. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  26. def makeAlternative(ts: List[Global.Tree]): Global.Tree

    Create tree for a pattern alternative

  27. def makeAnnotated(t: Global.Tree, annot: Global.Tree): Global.Tree

  28. def makeAssign(lhs: Global.Tree, rhs: Global.Tree): Global.Tree

    Create a tree representing an assignment <lhs = rhs>

  29. def makeBinop(isExpr: Boolean, left: Global.Tree, op: Global.TermName, right: Global.Tree, opPos: Global.Position): Global.Tree

    Create tree representing (unencoded) binary operation expression or pattern.

  30. def makeBlock(stats: List[Global.Tree]): Global.Tree

    Create block of statements stats

  31. def makeCaseDef(pat: Global.Tree, guard: Global.Tree, rhs: Global.Tree): Global.CaseDef

    Create tree for case definition <case pat if guard => rhs>

  32. def makeCatchFromExpr(catchExpr: Global.Tree): Global.CaseDef

    Creates tree representing: { case x: Throwable => val catchFn = catchExpr if (catchFn isDefinedAt x) catchFn(x) else throw x }

  33. def makeDoWhile(lname: Global.TermName, body: Global.Tree, cond: Global.Tree): Global.Tree

    Create tree representing a do-while loop

  34. def makeFilter(tree: Global.Tree, condition: Global.Tree, scrutineeName: String): Global.Tree

  35. def makeFor(enums: List[Enumerator], body: Global.Tree): Global.Tree

    Create tree for for-do comprehension <for (enums) body>

  36. def makeForYield(enums: List[Enumerator], body: Global.Tree): Global.Tree

    Create tree for for-yield comprehension <for (enums) yield body>

  37. def makeFunctionTypeTree(argtpes: List[Global.Tree], restpe: Global.Tree): Global.Tree

    Create a tree representing the function type (argtpes) => restpe

  38. def makeGenerator(pos: Global.Position, pat: Global.Tree, valeq: Boolean, rhs: Global.Tree): Enumerator

    Create tree for for-comprehension generator <val pat0 <- rhs0>

  39. def makeImportSelector(name: Global.Name, nameOffset: Int): Global.ImportSelector

  40. def makeIntersectionTypeTree(tps: List[Global.Tree]): Global.Tree

    A type tree corresponding to (possibly unary) intersection type

  41. def makeLifted(gs: List[ValFrom], body: Global.Tree): Global.Tree

    Create tree for a lifted expression XX-LIFTING

  42. def makeNew(parents: List[Global.Tree], self: Global.ValDef, stats: List[Global.Tree], argss: List[List[Global.Tree]], npos: Global.Position, cpos: Global.Position): Global.Tree

    Create positioned tree representing an object creation <new parents { stats }

    Create positioned tree representing an object creation <new parents { stats }

    npos

    the position of the new

    cpos

    the position of the anonymous class starting with parents

  43. def makeParam(pname: Global.TermName, tpe: Global.Tree): Global.ValDef

  44. def makePatDef(mods: Global.Modifiers, pat: Global.Tree, rhs: Global.Tree): List[Global.Tree]

    Create tree for pattern definition <mods val pat0 = rhs>

  45. def makePatDef(pat: Global.Tree, rhs: Global.Tree): List[Global.Tree]

    Create tree for pattern definition <val pat0 = rhs>

  46. def makeSelfDef(name: Global.TermName, tpt: Global.Tree): Global.ValDef

  47. def makeSyntheticParam(pname: Global.TermName): Global.ValDef

  48. def makeSyntheticTypeParam(pname: Global.TypeName, bounds: Global.Tree): Global.TypeDef

  49. def makeTupleTerm(trees: List[Global.Tree], flattenUnary: Boolean): Global.Tree

  50. def makeTupleType(trees: List[Global.Tree], flattenUnary: Boolean): Global.Tree

  51. def makeVisitor(cases: List[Global.CaseDef], checkExhaustive: Boolean, prefix: String): Global.Tree

    Create visitor <x => x match cases>

  52. def makeVisitor(cases: List[Global.CaseDef], checkExhaustive: Boolean): Global.Tree

    Create visitor <x => x match cases>

  53. def makeWhile(lname: Global.TermName, cond: Global.Tree, body: Global.Tree): Global.Tree

    Create tree representing a while loop

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

    Definition Classes
    AnyRef
  55. final def notify(): Unit

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

    Definition Classes
    AnyRef
  57. def productConstr: Global.Select

  58. def productConstrN(n: Int): Global.Select

  59. def repeatedApplication(tpe: Global.Tree): Global.Tree

  60. def rootId(name: Global.Name): Global.Select

  61. def rootScalaDot(name: Global.Name): Global.Select

  62. def scalaAnyConstr: Global.Select

  63. def scalaAnyRefConstr: Global.Select

  64. def scalaAnyValConstr: Global.Select

  65. def scalaDot(name: Global.Name): Global.Select

  66. def scalaUnitConstr: Global.Select

  67. def serializableConstr: Global.Select

  68. def stripParens(t: Global.Tree): Global.Tree

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

    Definition Classes
    AnyRef
  70. def toString(): String

    Definition Classes
    AnyRef → Any
  71. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws()
  74. def [B](y: B): (TreeBuilder, B)

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to ArrowAssoc[TreeBuilder] performed by method any2ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc

Shadowed Implict Value Members

  1. val self: Any

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to StringAdd performed by method any2stringadd in scala.Predef.
    Shadowing
    This implicitly inherited member is ambiguous. One or more implicitly inherited members have similar signatures, so calling this member may produce an ambiguous implicit conversion compiler error.
    To access this member you can use a type ascription:
    (treeBuilder: StringAdd).self
    Definition Classes
    StringAdd
  2. val self: Any

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to StringFormat performed by method any2stringfmt in scala.Predef.
    Shadowing
    This implicitly inherited member is ambiguous. One or more implicitly inherited members have similar signatures, so calling this member may produce an ambiguous implicit conversion compiler error.
    To access this member you can use a type ascription:
    (treeBuilder: StringFormat).self
    Definition Classes
    StringFormat

Deprecated Value Members

  1. def x: TreeBuilder

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to ArrowAssoc[TreeBuilder] performed by method any2ArrowAssoc in scala.Predef.
    Shadowing
    This implicitly inherited member is ambiguous. One or more implicitly inherited members have similar signatures, so calling this member may produce an ambiguous implicit conversion compiler error.
    To access this member you can use a type ascription:
    (treeBuilder: ArrowAssoc[TreeBuilder]).x
    Definition Classes
    ArrowAssoc
    Annotations
    @deprecated
    Deprecated

    (Since version 2.10.0) Use leftOfArrow instead

  2. def x: TreeBuilder

    Implicit information
    This member is added by an implicit conversion from TreeBuilder to Ensuring[TreeBuilder] performed by method any2Ensuring in scala.Predef.
    Shadowing
    This implicitly inherited member is ambiguous. One or more implicitly inherited members have similar signatures, so calling this member may produce an ambiguous implicit conversion compiler error.
    To access this member you can use a type ascription:
    (treeBuilder: Ensuring[TreeBuilder]).x
    Definition Classes
    Ensuring
    Annotations
    @deprecated
    Deprecated

    (Since version 2.10.0) Use resultOfEnsuring instead

Inherited from AnyRef

Inherited from Any

Inherited by implicit conversion any2stringadd from TreeBuilder to StringAdd

Inherited by implicit conversion any2stringfmt from TreeBuilder to StringFormat

Inherited by implicit conversion any2ArrowAssoc from TreeBuilder to ArrowAssoc[TreeBuilder]

Inherited by implicit conversion any2Ensuring from TreeBuilder to Ensuring[TreeBuilder]

No Group