Re: PDD 15 - accessing parent's attributes

2007-09-24 Thread Allison Randal
Jonathan Worthington wrote: PMC* get_attr_keyed(PMC* key, STRING* idx) void set_attr_keyed(PMC* key, STRING* idx, PMC* value) :write _keyed is consistent, but not particularly descriptive - it's not *really* a keyed access that we're doing here. _super maybe is better, though I'm not sure I li

Re: PDD 15 - accessing parent's attributes

2007-09-04 Thread Jonathan Worthington
Allison Randal wrote: We need a new syntax for the new metamodel. I'm thinking of: setattribute obj, ["Foo"], "j", $P4 That works for me. It uses the familiar keyed access syntax to allow multi-level parent class names. We would need to add two additional vtable entries get_attr_keyed and

Re: PDD 15 - accessing parent's attributes

2007-09-04 Thread Patrick R. Michaud
On Mon, Sep 03, 2007 at 10:49:57AM -0700, Allison Randal wrote: > Both the old and new metamodels allow you to set and get an attribute > for a parent class that has the same name as an attribute in the child > class (Perl 6 and .NET both use this feature in different forms). The > old metamodel

PDD 15 - accessing parent's attributes

2007-09-03 Thread Allison Randal
Both the old and new metamodels allow you to set and get an attribute for a parent class that has the same name as an attribute in the child class (Perl 6 and .NET both use this feature in different forms). The old metamodel used this syntax: # Foo has an attribute named 'j' newclass $P1,