Proposal
Fields annotated @scala.static
are generated as static fields.
The this
identifier is not in scope in static field initialization expressions.
A static field x
defined in a class C
can be referenced as scala.static[C].x
.
If the field is variable, it can be updated as scala.static[C].x = t
.
A static field y
defined in a singleton object C
can be directly referenced as C.x
and updated as C.x = t
.