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

Re: autoload

On 09/19/2015 10:41 PM, Bart Schaefer wrote:
} -"zcompile ... (N-.:t)" ... or it barfs if there's a directory on the
} same path. Fussy fussy.

You *really* don't want that :t in there.

Yup. It turns out that it was the regular versions of the functions that were being found.
This is for all practical purposes impossible to do automatically.

Sure, I can't argue, you know how it works. My dream of simplicity may indeed be impossible. But you know what's in my head--something that's the equivalent of 'just sourcing' your functions, but doing it from precompiled code, and not pre-loading anything at all, but doing it only when the function is actually called. Nuts, it's so elegant in theory. I'm sorta in love with the idea but implementation becomes
a can of worms.
} and not try to digest existing .zwc's,
} and not worry about directories.

This is a philosophical issue along the same lines as CSH_NULL_GLOB.
If I name a bunch of things and some of them are wrong, should the
shell complain about them or not, and either way, should it skip
them and continue working on the ones that are correct?  Which is
more likely to produce the final result that the user expected?
Indeed, and the right answer is not obvious.  Hand holding tends to end up
creating more problems that it solves. I'd suppose that if there are built in
exceptions to the plain reading of a command it must be exceptions that
could never be desired ever, like, perhaps, including a .zwc inside it's own
replacement. Or not.  I always hated Microsoft for making 80% of things
easier and the remaining 20% impossible.  If it has to be tough, then it has
to be tough.

You know Bart, with all the time you've spent on this, you could have written
that HOWTO ;-)

Seriously, it requires something broader than just reading the manual.

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