CrossVersionChecks

dotty.tools.dotc.transform.CrossVersionChecks
See theCrossVersionChecks companion class

Attributes

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

Members list

Value members

Concrete methods

def checkRef(sym: Symbol, pos: SrcPos)(using Context): Unit

Check that a reference to an experimental definition with symbol sym meets cross-version constraints for @deprecated and @experimental.

Check that a reference to an experimental definition with symbol sym meets cross-version constraints for @deprecated and @experimental.

Attributes

Decide whether the deprecation of sym should be ignored in this context.

Decide whether the deprecation of sym should be ignored in this context.

The warning is skipped if any symbol in the context owner chain is deprecated, that is, an enclosing scope is associated with a deprecated symbol.

Further exclusions are needed for enums and case classes, since they typically need to refer to deprecated members even if the enclosing enum or case class is not deprecated.

If and only if sym is an enum case, the warning is skipped if an enclosing scope is either a module that declares sym, or the companion class of the module that declares sym.

For a deprecated case class or case class element, the warning is skipped for synthetic sites where the enclosing class (or its companion) is either the deprecated case class or the case class of the deprecated element.

Attributes

Concrete fields

val name: String