[plt-scheme] scheme/class: attaching properties to classes
At Fri, 12 Sep 2008 09:30:54 +0100, Dave Gurnell wrote:
> Is there any way of attaching properties to classes?
Not currently.
A potential problem is that a property (through its guard) can get
information about the structure type that it is attached to, but the
representation of objects is supposed to be private.
So far, our strategy has been to include direct support for some
trusted properties, such as the one for serialization.
> I'm thinking particularly of prop:custom-write, which would let me
> implement a to-string method.
We should build support for custom writing into the class system (like
for serialization). I remember that you've asked once before already,
and I'll try to add it soon.
Matthew