untpd

object untpd extends Instance[Untyped] with UntypedTreeInfo
class Object
trait Matchable
class Any
untpd.type

Type members

Classlikes

case class ContextBounds(bounds: TypeBoundsTree, cxBounds: List[Tree])(implicit @constructorOnly src: SourceFile) extends TypTree
case class DependentTypeTree(tp: List[Symbol] => Type)(implicit @constructorOnly src: SourceFile) extends Tree[Untyped]

Short-lived usage in typer, does not need copy/transform/fold infrastructure

Short-lived usage in typer, does not need copy/transform/fold infrastructure

abstract class DerivedTypeTree(implicit @constructorOnly src: SourceFile) extends TypeTree[Untyped]

A type tree that gets its type from some other tree's symbol. Enters the type tree in the References attachment of the from tree as a side effect.

A type tree that gets its type from some other tree's symbol. Enters the type tree in the References attachment of the from tree as a side effect.

class DerivingTemplate(constr: DefDef, parentsOrDerived: List[Tree], self: ValDef, preBody: LazyTreeList, derivedCount: Int)(implicit @constructorOnly src: SourceFile) extends Template[Untyped]

An untyped template with a derives clause. Derived parents are added to the end of the parents list. derivedCount keeps track of how many there are. This representation was chosen because it balances two concerns:

An untyped template with a derives clause. Derived parents are added to the end of the parents list. derivedCount keeps track of how many there are. This representation was chosen because it balances two concerns:

  • maximize overlap between DerivingTemplate and Template for code streamlining
  • keep invariant that elements of untyped trees align with source positions
case class ExtMethods(paramss: List[ParamClause], methods: List[Tree])(implicit @constructorOnly src: SourceFile) extends Tree[Untyped]
case class ForDo(enums: List[Tree], body: Tree)(implicit @constructorOnly src: SourceFile) extends TermTree
case class ForYield(enums: List[Tree], expr: Tree)(implicit @constructorOnly src: SourceFile) extends TermTree
case class Function(args: List[Tree], body: Tree)(implicit @constructorOnly src: SourceFile) extends Tree[Untyped]

A function type

A function type

class FunctionWithMods(args: List[Tree], body: Tree, val mods: Modifiers)(implicit @constructorOnly src: SourceFile) extends Function

A function type with implicit, erased, or given modifiers

A function type with implicit, erased, or given modifiers

case class GenAlias(pat: Tree, expr: Tree)(implicit @constructorOnly src: SourceFile) extends Tree[Untyped]

An enum to control checking or filtering of patterns in GenFrom trees

An enum to control checking or filtering of patterns in GenFrom trees

case class GenFrom(pat: Tree, expr: Tree, checkMode: GenCheckMode)(implicit @constructorOnly src: SourceFile) extends Tree[Untyped]
case class ImportSelector(imported: Ident, renamed: Tree, bound: Tree)(implicit @constructorOnly src: SourceFile) extends Tree[Untyped]
case class InfixOp(left: Tree, op: Ident, right: Tree)(implicit @constructorOnly src: SourceFile) extends OpTree
case class InterpolatedString(id: TermName, segments: List[Tree])(implicit @constructorOnly src: SourceFile) extends TermTree

An interpolated string

An interpolated string

Value parameters:
segments

a list of two element tickets consisting of string literal and argument tree, possibly with a simple string literal as last element of the list

case class MacroTree(expr: Tree)(implicit @constructorOnly src: SourceFile) extends Tree[Untyped]
sealed abstract class Mod(val flags: FlagSet)(implicit @constructorOnly src: SourceFile) extends Positioned

Mod is intended to record syntactic information about modifiers, it's NOT a replacement of FlagSet.

Mod is intended to record syntactic information about modifiers, it's NOT a replacement of FlagSet.

For any query about semantic information, check flags instead.

Companion:
object
object Mod
Companion:
class
case class Modifiers(flags: FlagSet, privateWithin: TypeName, annotations: List[Tree], mods: List[Mod])

Modifiers and annotations for definitions

Modifiers and annotations for definitions

Value parameters:
annotations

The annotations preceding the modifiers

flags

The set flags

privateWithin

If a private or protected has is followed by a qualifier [q], the name q, "" as a typename otherwise.

case class ModuleDef(name: TermName, impl: Template)(implicit @constructorOnly src: SourceFile) extends MemberDef[Untyped]

mods object name impl

mods object name impl

case class Number(digits: String, kind: NumberKind)(implicit @constructorOnly src: SourceFile) extends TermTree
abstract class OpTree(implicit @constructorOnly src: SourceFile) extends Tree[Untyped]
case class Parens(t: Tree)(implicit @constructorOnly src: SourceFile) extends ProxyTree[Untyped]
case class ParsedTry(expr: Tree, handler: Tree, finalizer: Tree)(implicit @constructorOnly src: SourceFile) extends TermTree
case class PatDef(mods: Modifiers, pats: List[Tree], tpt: Tree, rhs: Tree)(implicit @constructorOnly src: SourceFile) extends DefTree
case class PolyFunction(targs: List[Tree], body: Tree)(implicit @constructorOnly src: SourceFile) extends Tree[Untyped]

A polymorphic function type

A polymorphic function type

case class PostfixOp(od: Tree, op: Ident)(implicit @constructorOnly src: SourceFile) extends OpTree
case class PrefixOp(op: Ident, od: Tree)(implicit @constructorOnly src: SourceFile) extends OpTree
case class Quote(quoted: Tree)(implicit @constructorOnly src: SourceFile) extends TermTree
case class Splice(expr: Tree)(implicit @constructorOnly src: SourceFile) extends TermTree
case class SymbolLit(str: String)(implicit @constructorOnly src: SourceFile) extends TermTree
case class Throw(expr: Tree)(implicit @constructorOnly src: SourceFile) extends TermTree
case class Tuple(trees: List[Tree])(implicit @constructorOnly src: SourceFile) extends Tree[Untyped]
case class TypSplice(expr: Tree)(implicit @constructorOnly src: SourceFile) extends TypTree
abstract case class TypedSplice(splice: Tree)(owner: Symbol, isExtensionReceiver: Boolean)(implicit @constructorOnly src: SourceFile) extends ProxyTree[Untyped]

A typed subtree of an untyped tree needs to be wrapped in a TypedSplice

A typed subtree of an untyped tree needs to be wrapped in a TypedSplice

Value parameters:
isExtensionReceiver

The splice was created from the receiver e in an extension method call e.f(...)

owner

The current owner at the time the tree was defined

Companion:
object
Companion:
class
class UntypedDeepFolder[X](f: (X, Tree) => X) extends UntypedTreeAccumulator[X]

Fold f over all tree nodes, in depth-first, prefix order

Fold f over all tree nodes, in depth-first, prefix order

abstract class UntypedTreeAccumulator[X] extends TreeAccumulator[X]
abstract class UntypedTreeMap(cpy: UntypedTreeCopier) extends TreeMap
class WildcardFunction(placeholderParams: List[ValDef], body: Tree)(implicit @constructorOnly src: SourceFile) extends Function

A function created from a wildcard expression

A function created from a wildcard expression

Value parameters:
body

the function body where wildcards are replaced by references to synthetic parameters. This is equivalent to Function, except that forms a special case for the overlapping positions tests.

placeholderParams

a list of definitions of synthetic parameters.

class XMLBlock(stats: List[Tree], expr: Tree)(implicit @constructorOnly src: SourceFile) extends Block[Untyped]

A block generated by the XML parser, only treated specially by Positioned#checkPos

A block generated by the XML parser, only treated specially by Positioned#checkPos

Inherited classlikes

class DeepFolder[X](f: (X, Tree) => X) extends TreeAccumulator[X]

Fold f over all tree nodes, in depth-first, prefix order

Fold f over all tree nodes, in depth-first, prefix order

Inherited from:
Instance
object IdPattern

An extractor for trees of the form id or id: T

An extractor for trees of the form id or id: T

Inherited from:
UntypedTreeInfo
class MatchingArgs(params: List[Symbol], args: List[Tree])(using x$3: Context)
Inherited from:
TreeInfo
class ShallowFolder[X](f: (X, Tree) => X) extends TreeAccumulator[X]

Fold f over all tree nodes, in depth-first, prefix order, but don't visit subtrees where f returns a different result for the root, i.e. f(x, root) ne x.

Fold f over all tree nodes, in depth-first, prefix order, but don't visit subtrees where f returns a different result for the root, i.e. f(x, root) ne x.

Inherited from:
Instance
abstract class TreeAccumulator[X]
Inherited from:
Instance
abstract class TreeCopier

A class for copying trees. The copy methods avoid creating a new tree If all arguments stay the same.

A class for copying trees. The copy methods avoid creating a new tree If all arguments stay the same.

Note: Some of the copy methods take a context. These are exactly those methods that are overridden in TypedTreeCopier so that they selectively retype themselves. Retyping needs a context.

Inherited from:
Instance
abstract class TreeMap(val cpy: TreeCopier)
Inherited from:
Instance
abstract class TreeTraverser extends TreeAccumulator[Unit]
Inherited from:
Instance
object TypeDefs
Inherited from:
Instance
object ValDefs
Inherited from:
Instance

Inherited types

Inherited from:
Instance
Inherited from:
Instance
Inherited from:
Instance
type Apply = Apply[T]
Inherited from:
Instance
type Assign = Assign[T]
Inherited from:
Instance
type Bind = Bind[T]
Inherited from:
Instance
type Block = Block[T]
Inherited from:
Instance
Inherited from:
Instance
type CaseDef = CaseDef[T]
Inherited from:
Instance
type Closure = Closure[T]
Inherited from:
Instance
type DefDef = DefDef[T]
Inherited from:
Instance
type DefTree = DefTree[T]
Inherited from:
Instance
Inherited from:
Instance
type Export = Export[T]
Inherited from:
Instance
Inherited from:
Instance
type Hole = Hole[T]
Inherited from:
Instance
type Ident = Ident[T]
Inherited from:
Instance
type If = If[T]
Inherited from:
Instance
type Import = Import[T]
Inherited from:
Instance
Inherited from:
Instance
type InlineIf = InlineIf[T]
Inherited from:
Instance
Inherited from:
Instance
type Inlined = Inlined[T]
Inherited from:
Instance
Inherited from:
Instance
type Labeled = Labeled[T]
Inherited from:
Instance
Inherited from:
Instance
type LazyTree = LazyTree[T]
Inherited from:
Instance
Inherited from:
Instance
type Literal = Literal[T]
Inherited from:
Instance
type Match = Match[T]
Inherited from:
Instance
Inherited from:
Instance
Inherited from:
Instance
type NameTree = NameTree[T]
Inherited from:
Instance
type NamedArg = NamedArg[T]
Inherited from:
Instance
Inherited from:
Instance
type New = New[T]
Inherited from:
Instance
Inherited from:
Instance
Inherited from:
Instance
Inherited from:
Instance
Inherited from:
Instance
type RefTree = RefTree[T]
Inherited from:
Instance
Inherited from:
Instance
type Return = Return[T]
Inherited from:
Instance
type Select = Select[T]
Inherited from:
Instance
Inherited from:
Instance
Inherited from:
Instance
type Super = Super[T]
Inherited from:
Instance
type Template = Template[T]
Inherited from:
Instance
type TermTree = TermTree[T]
Inherited from:
Instance
type Thicket = Thicket[T]
Inherited from:
Instance
type This = This[T]
Inherited from:
Instance
type Tree = Tree[T]
Inherited from:
Instance
type Try = Try[T]
Inherited from:
Instance
type TypTree = TypTree[T]
Inherited from:
Instance
Inherited from:
Instance
Inherited from:
Instance
type TypeDef = TypeDef[T]
Inherited from:
Instance
type TypeTree = TypeTree[T]
Inherited from:
Instance
type Typed = Typed[T]
Inherited from:
Instance
type UnApply = UnApply[T]
Inherited from:
Instance
type ValDef = ValDef[T]
Inherited from:
Instance
Inherited from:
Instance
Inherited from:
Instance

Info of a variable in a pattern: The named tree and its type

Info of a variable in a pattern: The named tree and its type

Inherited from:
UntypedTreeInfo
type WhileDo = WhileDo[T]
Inherited from:
Instance

Value members

Concrete methods

def Alternative(trees: List[Tree])(implicit src: SourceFile): Alternative
def Annotated(arg: Tree, annot: Tree)(implicit src: SourceFile): Annotated
def AppliedTypeTree(tpt: Tree, args: List[Tree])(implicit src: SourceFile): AppliedTypeTree
def AppliedTypeTree(tpt: Tree, arg: Tree)(implicit src: SourceFile): AppliedTypeTree
def Apply(fun: Tree, args: List[Tree])(implicit src: SourceFile): Apply
def Apply(fn: Tree, arg: Tree)(implicit src: SourceFile): Apply
def Assign(lhs: Tree, rhs: Tree)(implicit src: SourceFile): Assign
def Bind(name: Name, body: Tree)(implicit src: SourceFile): Bind
def Block(stats: List[Tree], expr: Tree)(implicit src: SourceFile): Block
def Block(stat: Tree, expr: Tree)(implicit src: SourceFile): Block
def ByNameTypeTree(result: Tree)(implicit src: SourceFile): ByNameTypeTree
def CaseDef(pat: Tree, guard: Tree, body: Tree)(implicit src: SourceFile): CaseDef
def Closure(env: List[Tree], meth: Tree, tpt: Tree)(implicit src: SourceFile): Closure
def DefDef(name: TermName, paramss: List[ParamClause], tpt: Tree, rhs: LazyTree)(implicit src: SourceFile): DefDef
def Export(expr: Tree, selectors: List[ImportSelector])(implicit src: SourceFile): Export
def Hole(isTermHole: Boolean, idx: Int, args: List[Tree], content: Tree, tpt: Tree)(implicit src: SourceFile): Hole
def Ident(name: Name)(implicit src: SourceFile): Ident
def If(cond: Tree, thenp: Tree, elsep: Tree)(implicit src: SourceFile): If
def Import(expr: Tree, selectors: List[ImportSelector])(implicit src: SourceFile): Import
def InlineIf(cond: Tree, thenp: Tree, elsep: Tree)(implicit src: SourceFile): If
def InlineMatch(selector: Tree, cases: List[CaseDef])(implicit src: SourceFile): Match
def Inlined(call: Tree, bindings: List[MemberDef], expansion: Tree)(implicit src: SourceFile): Inlined
def JavaSeqLiteral(elems: List[Tree], elemtpt: Tree)(implicit src: SourceFile): JavaSeqLiteral
def Labeled(bind: Bind, expr: Tree)(implicit src: SourceFile): Labeled
def LambdaTypeTree(tparams: List[TypeDef], body: Tree)(implicit src: SourceFile): LambdaTypeTree
def Literal(const: Constant)(implicit src: SourceFile): Literal
def Match(selector: Tree, cases: List[CaseDef])(implicit src: SourceFile): Match
def MatchTypeTree(bound: Tree, selector: Tree, cases: List[CaseDef])(implicit src: SourceFile): MatchTypeTree
def NamedArg(name: Name, arg: Tree)(implicit src: SourceFile): NamedArg
def New(tpt: Tree)(implicit src: SourceFile): New
def New(tpt: Tree, argss: List[List[Tree]])(using Context): Tree

new T(args1)...(args_n) ==> new T.Ts...(args_n)

new T(args1)...(args_n) ==> new T.Ts...(args_n)

where Ts are the class type arguments of T or its class type alias. Note: we also keep any type arguments as parts of T. This is necessary to allow navigation into these arguments from the IDE, and to do the right thing in PrepareInlineable.

def PackageDef(pid: RefTree, stats: List[Tree])(implicit src: SourceFile): PackageDef
def RefinedTypeTree(tpt: Tree, refinements: List[Tree])(implicit src: SourceFile): RefinedTypeTree
def Return(expr: Tree, from: Tree)(implicit src: SourceFile): Return
def SearchFailureIdent(name: Name, explanation: => String)(implicit src: SourceFile): SearchFailureIdent
def Select(qualifier: Tree, name: Name)(implicit src: SourceFile): Select
def SelectWithSig(qualifier: Tree, name: Name, sig: Signature)(implicit src: SourceFile): Select
def SeqLiteral(elems: List[Tree], elemtpt: Tree)(implicit src: SourceFile): SeqLiteral
def Super(qual: Tree, mix: Ident)(implicit src: SourceFile): Super
def Template(constr: DefDef, parents: List[Tree], derived: List[Tree], self: ValDef, body: LazyTreeList)(implicit src: SourceFile): Template
def TermLambdaTypeTree(params: List[ValDef], body: Tree)(implicit src: SourceFile): TermLambdaTypeTree
def This(qual: Ident)(implicit src: SourceFile): This
def Try(expr: Tree, cases: List[CaseDef], finalizer: Tree)(implicit src: SourceFile): Try
def TypeApply(fun: Tree, args: List[Tree])(implicit src: SourceFile): TypeApply
def TypeBoundsTree(lo: Tree, hi: Tree, alias: Tree)(implicit src: SourceFile): TypeBoundsTree
def TypeDef(name: TypeName, rhs: Tree)(implicit src: SourceFile): TypeDef
def TypeTree()(implicit src: SourceFile): TypeTree
def TypeTree(tpe: Type)(using Context): TypedSplice
def Typed(expr: Tree, tpt: Tree)(implicit src: SourceFile): Typed
def UnApply(fun: Tree, implicits: List[Tree], patterns: List[Tree])(implicit src: SourceFile): UnApply
def ValDef(name: TermName, tpt: Tree, rhs: LazyTree)(implicit src: SourceFile): ValDef
def WhileDo(cond: Tree, body: Tree)(implicit src: SourceFile): WhileDo
def ensureApplied(tpt: Tree)(implicit src: SourceFile): Tree
def javaDotLangDot(name: Name)(implicit src: SourceFile): Select
def lambdaAbstract(params: List[ValDef] | List[TypeDef], tpt: Tree)(using Context): Tree
def lambdaAbstractAll(paramss: List[List[ValDef] | List[TypeDef]], tpt: Tree)(using Context): Tree
def localCtx(tree: Tree)(using Context): Context

The context to use when mapping or accumulating over a tree

The context to use when mapping or accumulating over a tree

def makeAndType(left: Tree, right: Tree)(using Context): AppliedTypeTree
def makeConstructor(tparams: List[TypeDef], vparamss: List[List[ValDef]], rhs: Tree)(using Context): DefDef
def makeNew(tpt: Tree)(using Context): Tree

A new expression with constrictor and possibly type arguments. See New(tpt, argss) for details.

A new expression with constrictor and possibly type arguments. See New(tpt, argss) for details.

def makeParameter(pname: TermName, tpe: Tree, mods: Modifiers, isBackquoted: Boolean)(using Context): ValDef
def makeSelfDef(name: TermName, tpt: Tree)(using Context): ValDef
def makeSyntheticParameter(n: Int, tpt: Tree | Null, flags: FlagSet)(using Context): ValDef
def makeTuple(ts: List[Tree])(using Context): Tree
def rawRef(tp: NamedType)(using Context): Tree
def ref(tp: NamedType)(using Context): Tree
def ref(sym: Symbol)(using Context): Tree
def refOfDef(tree: MemberDef)(using Context): Tree

A reference to given definition. If definition is a repeated parameter, the reference will be a repeated argument.

A reference to given definition. If definition is a repeated parameter, the reference will be a repeated argument.

def repeated(arg: Tree)(using Context): Typed

A repeated argument such as arg: _*

A repeated argument such as arg: _*

def rootDot(name: Name)(implicit src: SourceFile): Select
def scalaAny(implicit src: SourceFile): Select
def scalaDot(name: Name)(implicit src: SourceFile): Select
def scalaUnit(implicit src: SourceFile): Select
def unitLiteral(implicit src: SourceFile): Literal

Inherited methods

def Thicket(xs: List[Tree])(implicit src: SourceFile): Thicket[Untyped]
Inherited from:
Instance
def Thicket(x1: Tree, x2: Tree, x3: Tree)(implicit src: SourceFile): Thicket
Inherited from:
Instance
def Thicket(x1: Tree, x2: Tree)(implicit src: SourceFile): Thicket
Inherited from:
Instance
Inherited from:
Instance
def allArguments(tree: Tree): List[Tree]

All term arguments of an application in a single flattened list

All term arguments of an application in a single flattened list

Inherited from:
TreeInfo
def allParamSyms(ddef: DefDef)(using Context): List[Symbol]

All type and value parameter symbols of this DefDef

All type and value parameter symbols of this DefDef

Inherited from:
TreeInfo
def applyOverloaded(receiver: Tree, method: TermName, args: List[Tree], targs: List[Type], expectedType: Type)(using parentCtx: Context): Tree

Construct the application $receiver.$method[$targs]($args) using overloading resolution to find a matching overload of $method if necessary. This is useful when overloading resolution needs to be performed in a phase after typer. Note that this will not perform any kind of implicit search.

Construct the application $receiver.$method[$targs]($args) using overloading resolution to find a matching overload of $method if necessary. This is useful when overloading resolution needs to be performed in a phase after typer. Note that this will not perform any kind of implicit search.

Value parameters:
expectedType

An expected type of the application used to guide overloading resolution

Inherited from:
Instance
Inherited from:
Instance
def bodyKind(body: List[Tree])(using Context): FlagSet

The largest subset of {NoInits, PureInterface} that a trait or class with this body can have as flags.

The largest subset of {NoInits, PureInterface} that a trait or class with this body can have as flags.

Inherited from:
UntypedTreeInfo
def catchesAllOf(cdef: CaseDef, threshold: Type)(using Context): Boolean

Does this CaseDef catch everything of a certain Type?

Does this CaseDef catch everything of a certain Type?

Inherited from:
TreeInfo

Does this CaseDef catch Throwable?

Does this CaseDef catch Throwable?

Inherited from:
TreeInfo

The first constructor definition in stats

The first constructor definition in stats

Inherited from:
TreeInfo
def flatTree(xs: List[Tree])(implicit src: SourceFile): Tree
Inherited from:
Instance

Checks whether predicate p is true for all result parts of this expression, where we zoom into Ifs, Matches, and Blocks.

Checks whether predicate p is true for all result parts of this expression, where we zoom into Ifs, Matches, and Blocks.

Inherited from:
TreeInfo
def hasNamedArg(args: List[Any]): Boolean

Does this list contain a named argument tree?

Does this list contain a named argument tree?

Inherited from:
TreeInfo
protected def inlineContext(call: Tree)(using Context): Context

For untyped trees, this is just the identity. For typed trees, a context derived form ctx that records call as the innermost enclosing call for which the inlined version is currently processed.

For untyped trees, this is just the identity. For typed trees, a context derived form ctx that records call as the innermost enclosing call for which the inlined version is currently processed.

Inherited from:
Instance

Is tree a backquoted identifier or definition

Is tree a backquoted identifier or definition

Inherited from:
TreeInfo

Is tree an context function or closure, possibly nested in a block?

Is tree an context function or closure, possibly nested in a block?

Inherited from:
UntypedTreeInfo
Inherited from:
TreeInfo

Is this pattern node a catch-all (wildcard or variable) pattern?

Is this pattern node a catch-all (wildcard or variable) pattern?

Inherited from:
TreeInfo
def isFunction(tree: Tree): Boolean
Inherited from:
UntypedTreeInfo

Is this case guarded?

Is this case guarded?

Inherited from:
TreeInfo
def isOpAssign(tree: Tree): Boolean
Inherited from:
TreeInfo
def isPath(tree: Tree): Boolean

Is tree a path?

Is tree a path?

Inherited from:
TreeInfo

Is tpt a vararg type of the form T* or => T*?

Is tpt a vararg type of the form T* or => T*?

Inherited from:
TreeInfo

Is tree a self constructor call this(...)? I.e. a call to a constructor of the same object?

Is tree a self constructor call this(...)? I.e. a call to a constructor of the same object?

Inherited from:
TreeInfo
Inherited from:
TreeInfo

Is tree a super constructor call?

Is tree a super constructor call?

Inherited from:
TreeInfo
Inherited from:
TreeInfo
Inherited from:
Instance
Inherited from:
TreeInfo

Is this parameter list a using clause?

Is this parameter list a using clause?

Inherited from:
TreeInfo
Inherited from:
TreeInfo

Is tree a variable pattern?

Is tree a variable pattern?

Inherited from:
TreeInfo

Is the argument a wildcard argument of the form _ or x @ _?

Is the argument a wildcard argument of the form _ or x @ _?

Inherited from:
TreeInfo

Is this argument node of the form *, or is it a reference to such an argument ? The latter case can happen when an argument is lifted.

Is this argument node of the form *, or is it a reference to such an argument ? The latter case can happen when an argument is lifted.

Inherited from:
TreeInfo

Does this argument list end with an argument of the form : _* ?

Does this argument list end with an argument of the form : _* ?

Inherited from:
TreeInfo
def joinParams(tparams: List[TypeDef], paramss: List[ParamClause]): List[ParamClause]

If tparams is non-empty, add it to the left paramss, merging it with a leading type parameter list of paramss, if one exists.

If tparams is non-empty, add it to the left paramss, merging it with a leading type parameter list of paramss, if one exists.

Inherited from:
Instance

If path looks like a language import, Some(name) where name is experimental if that sub-module is imported, and the empty term name otherwise.

If path looks like a language import, Some(name) where name is experimental if that sub-module is imported, and the empty term name otherwise.

Inherited from:
TreeInfo
def methPart(tree: Tree): Tree

The method part of an application node, possibly enclosed in a block with only valdefs as statements. the reason for also considering blocks is that named arguments can transform a call into a block, e.g. (b = foo, a = bar) is transformed to { val x$1 = foo val x$2 = bar (x$2, x$1) }

The method part of an application node, possibly enclosed in a block with only valdefs as statements. the reason for also considering blocks is that named arguments can transform a call into a block, e.g. (b = foo, a = bar) is transformed to { val x$1 = foo val x$2 = bar (x$2, x$1) }

Inherited from:
TreeInfo
def numArgs(tree: Tree): Int

The number of arguments in an application

The number of arguments in an application

Inherited from:
TreeInfo
def parentsKind(parents: List[Tree])(using Context): FlagSet

The largest subset of {NoInits, PureInterface} that a trait or class with these parents can have as flags.

The largest subset of {NoInits, PureInterface} that a trait or class with these parents can have as flags.

Inherited from:
TreeInfo
def rename(tree: NameTree, newName: Name)(using Context): ThisTree[Untyped]
Inherited from:
Instance
def resolveConstructor(atp: Type, args: List[Tree])(using Context): Tree
Inherited from:
Instance
protected def skipTransform(tree: Tree)(using Context): Boolean

Hook to indicate that a transform of some subtree should be skipped

Hook to indicate that a transform of some subtree should be skipped

Inherited from:
Instance
Inherited from:
TreeInfo
def stripApply(tree: Tree): Tree

If this is an application, its function part, stripping all Apply nodes (but leaving TypeApply nodes in). Otherwise the tree itself.

If this is an application, its function part, stripping all Apply nodes (but leaving TypeApply nodes in). Otherwise the tree itself.

Inherited from:
TreeInfo
def stripBlock(tree: Tree): Tree

If this is a block, its expression part

If this is a block, its expression part

Inherited from:
TreeInfo
def stripInlined(tree: Tree): Tree
Inherited from:
TreeInfo
Inherited from:
Instance
def transformCtx(tree: Tree)(using Context): Context

The context to use when transforming a tree. It ensures that the source is correct, and that the local context is used if that's necessary for transforming the whole tree. TODO: ensure transform is always called with the correct context as argument

The context to use when transforming a tree. It ensures that the source is correct, and that the local context is used if that's necessary for transforming the whole tree. TODO: ensure transform is always called with the correct context as argument

See also:
Inherited from:
Instance
def unbind(x: Tree): Tree

The underlying pattern ignoring any bindings

The underlying pattern ignoring any bindings

Inherited from:
TreeInfo
override def unsplice(tree: Tree): Tree

The underlying tree when stripping any TypedSplice or Parens nodes

The underlying tree when stripping any TypedSplice or Parens nodes

Definition Classes
Inherited from:
UntypedTreeInfo

Concrete fields

Property key for contextual Apply trees of the form fn given arg

Property key for contextual Apply trees of the form fn given arg

Property key for TypeTrees marked with TypeRefOfSym or InfoOfSym which contains the symbol of the original tree from which this TypeTree is derived.

Property key for TypeTrees marked with TypeRefOfSym or InfoOfSym which contains the symbol of the original tree from which this TypeTree is derived.

Property key containing TypeTrees whose type is computed from the symbol in this type. These type trees have marker trees TypeRefOfSym or InfoOfSym as their originals.

Property key containing TypeTrees whose type is computed from the symbol in this type. These type trees have marker trees TypeRefOfSym or InfoOfSym as their originals.

override val cpy: UntypedTreeCopier

Inherited fields

Inherited from:
Instance
Inherited from:
Instance
val isNamedArg: Any => Boolean
Inherited from:
TreeInfo

Extensions

Extensions

extension (tree: Tree)

Is there a subtree of this tree that satisfies predicate p?

Is there a subtree of this tree that satisfies predicate p?