Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: PATCH: wrapper functions in modules



Sven Wischnowsky wrote:
> Alternatively I could change the code so that a module cannot be
> unloaded if it has defined `after'-functions and there are currently
> shell functions being executed.

Would it be possible for zmodload in such circumstances to mark the
function for unloading after the wrapper has been called, and then do
so?

> I think we could even change the code so that unloading a module
> automatically removes builtins, conditions, and wrapper functions
> defined by it...

It's probably OK leaving that explicitly in the cleanup function until
it gets too unwieldy there.

> And another question: why is the variable containing the paths to
> module-directories named `module_path'? Comparing this with `fpath' I
> would have expected `mpath' (and `MPATH') or something like that.

And someone pointed out MODULE_PATH is a bit generic for a
shell-specific variable, you never know what something else is going
to do with the environment variable.

-- 
Peter Stephenson <pws@xxxxxxxxxxxxxxxxx>       Tel: +39 050 844536
WWW:  http://www.ifh.de/~pws/
Dipartimento di Fisica, Via Buonarroti 2, 56127 Pisa, Italy



Messages sorted by: Reverse Date, Date, Thread, Author