[plt-scheme] associating data with structure types

From: Benderjg2 at aol.com (Benderjg2 at aol.com)
Date: Sat Mar 20 19:03:22 EST 2004

>> You can add properties to structure types. That sounds like what you
>> need. You cannot use define-struct, tho. You have to use the
>> make-struct-type interface.

Neil,
By the way, hidden away inside WebIt! is a define-struct/prop
macro which makes it a bit easier to define a structure with 
properties. As well, it plays nice with define-struct: it can be
used to sub-type from a structure defined with define-struct,
and define-struct can be used to sub-type from a structure
defined with define-struct/prop.

See struct-prop.ss in the WebIt! distribution.

Jim



Posted on the users mailing list.