[Grace-core] Permitting multiple constructors and inheritance for classes
James Noble
kjx at ecs.vuw.ac.nz
Thu Feb 13 14:49:37 PST 2014
On 14/02/2014, at 10:51 AM, Michael Homer <Michael.Homer at ecs.vuw.ac.nz> wrote:
> Write "class method x {}" or "class inherits bar" inside a class body
> to put methods or inherits clauses into the class object rather than
> the instance.
Hmm, interesting!
I presume this works for all declarations: class var, class def, and class type?
These are in scope for "instances" because instances are lexically nested inside their classes.
(Technically, "class vars" will be class instance variables (one per subclass)
not true class variables (one shared by the class and all its subclasses)
could you paste this into the wiki as well?
thanks
James
More information about the Grace-core
mailing list