[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Property Lists

Whilst you were thinking about record types, did anyone have a look
at common-lisp style property lists?

After review, I think property lists are the superior approach.
They are more flexible and simpler, imposing less specific
requirements on the organization of code that uses them.  They
are more general, in that they can be used to implement srfi-9
record types easily, but srfi-9 record types are difficult to
use to implement them.

And being unordered and single-valued, property name/value pairs
can be implemented "under the hood" as hash tables, and then
a symbol could be used as a hash-table for any purpose.

So....  I think a hash-table implementation of property lists is
probably a better idea on several counts than record types as
defined in SRFI-9.  Definitely more appropriate to functional
rather than imperative programming, IMO.

Am I missing something important, or are records just something
that people missed from the C/++ world and wanted to import?