Re: Documentation strings for class-slots



ocorrain@xxxxxxxxx (Tiarnán Ó Corráin) writes:
is there any (quasi-portable) way to extract doc-strings for
individual class slots? The hyperspec is terse:

This standard prescribes no means to retrieve the documentation
strings for individual slots specified in a defclass form, but
implementations might still provide debugging tools and/or
programming language extensions which manipulate this
information. Implementors wishing to provide such support are
encouraged to consult the Metaobject Protocol for suggestions about
how this might be done.

Has any consensus been reached?

Even MOP doesn't specify anything to retrieve the slot documentation:

http://www.lisp.org/mop/dictionary.html#slotd-mo-readers



So, the portable thing to do, is either to fetch the sources, or to
shadow defclass to add the functionality you need; something like in:

http://www.informatimago.com/develop/lisp/small-cl-pgms/ibcl.lisp


--
__Pascal Bourguignon__ http://www.informatimago.com/

PLEASE NOTE: Some quantum physics theories suggest that when the
consumer is not directly observing this product, it may cease to
exist or will exist only in a vague and undetermined state.
.



Relevant Pages

  • Re: Comparing lists
    ... The list implementations has been tweaked to produce better performance appending and popping. ... I find the Python docs surprisingly good for even commercial documentation. ... Once you decide that isn't good enough, the burden on creating the documentation is getting substantial, especially given that you've already spent the effort to write the code and tests for it. ... However, "experimenting" puts the cost on the person who derives the benefit, and is thus likely to not be done in a slipshod way. ...
    (comp.lang.python)
  • Re: /sub/dir
    ... directory and namestring formats documented somewhere? ... The second form should be highly portable, at least to lisp ... implementations running on machines with hierarchical file systems. ... would have to be documented in the implementation documentation. ...
    (comp.lang.lisp)
  • Re: performance registry interface
    ... Shame on me for believing the documentation! ... >> retrieval buffer that ultimately lead to counters. ... >> attempts to retrieve performance blocks associated with the keys I listed. ...
    (microsoft.public.win32.programmer.kernel)
  • Re: Newbie memory management question
    ... sure to retrieve and clear all such places. ... implementations keep returning one error status forever. ... the sequence of mishappenings, or if the error flags are ...
    (comp.graphics.api.opengl)
  • Re: Documentation strings for class-slots
    ... This standard prescribes no means to retrieve the documentation ... Even MOP doesn't specify anything to retrieve the slot ...
    (comp.lang.lisp)