Loading info files



Rupert Swarbrick <rswarbrick at gmail.com> writes:
>>> That seems like a sensible thing to do. Maybe something like this?
>>>
>>>   register_info_file (path);
>>
>> How about load_documentation. We don't register anything else but we do
>> load stuff. Also the fact that it's a Texinfo file is incidental.
>
> That sounds sensible. I'll code up something soon.

Sorry for the late response! With the stuff I just posted, the API for
the rest of Maxima looks something like

(defpackage :cl-info
  (:use :common-lisp)
  (:export :info-pathname
           :register-document :deferred-register-document
           :search-documentation-exact :search-documentation-inexact))

What I forgot to say in the other email I just sent is that there's a
stab at generalisation too, so if someone wants to add another
documentation provider, the two should play nicely together.

REGISTER-DOCUMENT:
  Call this to say "Oi, have a look at this document now"

DEFERRED-REGISTER-DOCUMENT:
  Call this to say "Look at this document next time you need to.

SEARCH-DOCUMENTATION-EXACT: "?"

SEARCH-DOCUMENTATION-INEXACT: "??"

"REGISTER" rather than "LOAD" is sort of intentional: After I've loaded
something, I don't care whether the file disappears again. Here, we're
just storing some metadata about the actual documentation. But I'm not
massively invested in the choice of verb :-)

Rupert


PS: Yes, CL-INFO is a bit silly, but I thought that I'd try to get this
    and then the build system patches merged first, rather than figure
    out how to consistently rename the files to match a more sensible
    name for the package.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 315 bytes
Desc: not available
URL: <http://www.math.utexas.edu/pipermail/maxima/attachments/20130402/3d080647/attachment.pgp>;