Dotty Documentation

0.11.0-bin-SNAPSHOT

object ProtectedAccessors
extends Object

Add accessors for all protected accesses. An accessor is needed if according to the rules of the JVM a protected class member is not accesissible from the point of access, but is accessible if the access is from an enclosing class. In this point a public access method is placed in that enclosing class.

[-] Constructors

[-] Members

[+] val name : String
[+] def insideBoundaryOf ( sym: Symbol ) ( implicit ctx: Context ) : Boolean

Is the current context's owner inside the access boundary established by sym?

[+] def needsAccessor ( sym: Symbol ) ( implicit ctx: Context ) : Boolean

Do we need a protected accessor for accessing sym from the current context's owner?

[+] def needsAccessorIfNotInSubclass ( sym: Symbol ) ( implicit ctx: Context ) : Boolean

Do we need a protected accessor if the current context's owner is not in a subclass or subtrait of sym?