Whither SmallScript? (was Re: Integer micro-benchmarks)

David Simmons pulsar at qks.com
Wed May 2 02:34:33 EDT 2001


"Greg Ewing" <see at my.signature> wrote in message
news:3AEF7EE5.6A5B78C3 at my.signature...
> Martin von Loewis wrote:
> >
> > andy at toolshed.com (Andrew Hunt) writes:
> >
> > > Can you continue to dynamically add methods to classes at runtime?
> >
> > Yes, you can.
>
> You can also change the class of an object and rearrange
> the inheritance hierarchy at runtime, just in case you
> were wondering. And add or remove instance variables
> dynamically, too (I don't think that one is so easy in
> Smalltalk).

Sure you can; Smalltalk has been doing that kind of thing for decades.
Smalltalk is probably one of the premier languages for meta-object protocol
(schema) operations like your describing. It certainly helped to pioneer
this kind of technology along with Lisp.

In Smalltalk, there is just about nothing you can't dynamically restructure
in a running application. In many Smalltalk dialects that includes adding
arbitrary fields/variables and attributes to individual objects, changing a
class object into something else; or adding unique (instance specific)
behavior to individual objects.

-- Dave S.

>
> --
> Greg Ewing, Computer Science Dept, University of Canterbury,
> Christchurch, New Zealand
> To get my email address, please visit my web page:
> http://www.cosc.canterbury.ac.nz/~greg





More information about the Python-list mailing list