CheckCaptures

dotty.tools.dotc.cc.CheckCaptures
See theCheckCaptures companion class
object CheckCaptures

The capture checker

Attributes

Companion
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Type members

Classlikes

trait CheckerAPI

Attributes

Supertypes
class Object
trait Matchable
class Any
Known subtypes
case class Env(owner: Symbol, kind: EnvKind, captured: CaptureSet, outer0: Env | Null, nestedClosure: Symbol)

A class describing environments.

A class describing environments.

Value parameters

captured

the capture set containing all references to tracked free variables outside of boxes

kind

the environment's kind

nestedClosure

under deferredReaches: If this is an env of a method with an anonymous function or anonymous class as RHS, the symbol of that function or class. NoSymbol in all other cases.

outer0

the next enclosing environment

owner

the current owner

Attributes

Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
enum EnvKind

Attributes

Supertypes
trait Enum
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
class PathSelectionProto(val sym: Symbol, val pt: Type)(using x$3: Context) extends WildcardSelectionProto

A prototype that indicates selection with an immutable value

A prototype that indicates selection with an immutable value

Attributes

Supertypes
trait Serializable
trait Product
trait Equals
trait TermType
trait ProtoType
trait CachedType
class TypeProxy
class Type
trait Showable
trait Hashable
class Object
trait Matchable
class Any
Show all
final class SubstParamsMap(from: BindingType, to: List[Type])(using x$3: Context) extends ApproximatingTypeMap

Similar normal substParams, but this is an approximating type map that maps parameters in contravariant capture sets to the empty set.

Similar normal substParams, but this is an approximating type map that maps parameters in contravariant capture sets to the empty set.

Attributes

Supertypes
class TypeMap
trait Type => Type
class Object
trait Matchable
class Any
Show all

Value members

Concrete methods

def checkWellformed(parent: Tree, ann: Tree)(using Context): Unit

Check that a @retains annotation only mentions references that can be tracked. This check is performed at Typer.

Check that a @retains annotation only mentions references that can be tracked. This check is performed at Typer.

Attributes

Concrete fields

val name: String