This is the mail archive of the guile@cygnus.com mailing list for the guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Path searching.


Guile expects to find modules in its search path; as I understand things some
of this is hard coded in c, and some defined in boot-9. Is there a more general
abstraction to be had, as loading a file from a search path is needed by many
programmes. If guile is being used to extend an existing programme, or 
something that has to be compatible with an existing suite, it must be able
to co-operate with the existing code's ideas about where files go. The
functionality is broadly similar, so should we have some c-level code that
does something like

(open-file-from-path file path . mode)

This should be enough for the majority of programmes. Many refinements are 
possible (directory caching with a per-path hash table for fast lookup, or
complex priority predicates [ if there is an uncompressed version in directory y
load that, otherwise use the newest version in directory x, or ....]) and
may be needed in some cases.   

Or is this too trivial to break out as a seperate function?

Julian Satchell
<satchell@dera.gov.uk>