This is the mail archive of the
guile@sourceware.cygnus.com
mailing list for the Guile project.
Re: Docstrings and Reference manual (Re: Discussing Guile and revising interfaces)
Mikael Djurfeldt <mdj@mdj.nada.kth.se> writes:
> I think your suggestions are very interesting. The interface for such
> properties could be `procedure-property' et al. The properties need
> not be loaded to begin with, but can be loaded on demand from a
> database file.
Right. Any object which has a docstring may have properties in the same
way. Probably a general interface to properties like `get-property' may
be convenient:
(define (get-property obj key)
(or (object-property obj key)
(and (procedure? obj) (procedure-property obj key))
(find-property-from-database-file (object-name obj) key)))
Object names are really essential for this.
"Greg J. Badros" <gjb@cs.washington.edu> writes:
> As I think we agree, the properties should be added to the function, not
> the docstring, but otherwise sounds reasonable. What kinds of
> properties are you thinking about?
Any miscellaneous properties, such as file location (e.g., "alist.c:12"),
cross references, names of arguments (for procedures), and possible
value types (for customizable variables), can be included. I haven't
thought very details, but I need those information to implement the new
describe procedure.