Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

The start of objects, in object.ops

7 views
Skip to first unread message

Dan Sugalski

unread,
Jun 18, 2003, 7:52:31 AM6/18/03
to perl6-i...@perl.org
I've decided part of the implementation for objects, and started in
on the ops for them. Right now it's just a sketch, but the following
ops are going in:

newclass Px, Sy

Creates a new, standalone class named Sy, class PMC put in Px.

subclass Px, [SPy], [Sz]

Subclass $2, and put the new subclass PMC in $1, If $3 is specified
(it's optional) it'll be the name of the new subclass, otherwise an
anonymous subclass is created.

singleton Px

Takes the object in Px and puts it in its own anonymous subclass of
its current class.

class Px, Py

Gets the class PMC for the class in $2, puts it in $1

classname Sx, Py

Gets the name of the class in $2 puts it in $1.


This is hardly sufficient, of course, for a full implementation, but
it seems a good place to start.
--
Dan

--------------------------------------"it's like this"-------------------
Dan Sugalski even samurai
d...@sidhe.org have teddy bears and even
teddy bears get drunk

0 new messages