From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27975 invoked by alias); 21 Sep 2015 17:33:51 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 20614 Received: (qmail 3404 invoked from network); 21 Sep 2015 17:33:48 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.0 X-Authority-Analysis: v=2.1 cv=T/C1EZ6Q c=1 sm=1 tr=0 a=NzxVjh620SjOIGLlnxV8Cg==:117 a=NzxVjh620SjOIGLlnxV8Cg==:17 a=N659UExz7-8A:10 a=ve4LEGfB0ZU4LIAUch4A:9 a=pILNOxqGKmIA:10 Message-id: <5600386E.7060201@eastlink.ca> Date: Mon, 21 Sep 2015 10:03:42 -0700 From: Ray Andrews User-Agent: Mozilla/5.0 (X11; Linux i686; rv:31.0) Gecko/20100101 Icedove/31.7.0 MIME-version: 1.0 To: zsh-users@zsh.org Subject: Re: autoload References: <55FAE223.2080502@eastlink.ca> <150917103419.ZM10067@torch.brasslantern.com> <150918171441.ZM27212@torch.brasslantern.com> <55FD7982.9030505@eastlink.ca> <150919092922.ZM28214@torch.brasslantern.com> <55FDA5D3.9020304@eastlink.ca> <150919142243.ZM23634@torch.brasslantern.com> <55FE04AD.1070304@eastlink.ca> <150919224120.ZM4736@torch.brasslantern.com> <55FF3F7E.4060906@eastlink.ca> <150920211840.ZM31871@torch.brasslantern.com> In-reply-to: <150920211840.ZM31871@torch.brasslantern.com> Content-type: text/plain; charset=windows-1252; format=flowed Content-transfer-encoding: 7bit On 09/20/2015 09:18 PM, Bart Schaefer wrote: > Except for the point that "just sourcing" doesn't actually call the > function, everything you wrote is what DOES happen as long as the > functions are defined in separate files. Because the language is > interpreted, the shell itself can't decompose a file into individual > function entry points the way e.g. a linker can for a shared object. Really? That's hard to fathom. I source a file and it finds whatever functions may be in there, but they can't be packed into a .zwc file without worrying about it's name? I'll take that on authority, but it blows my breakers. I'd have thought it would be as transparent as: for aa in /aWorking/Zsh/Source/*; do source $aa; done ... becoming: zcompile --do_it /not-the-same-directory-dummy\!/Source.zwc /aWorking/Zsh/Source/* ... but if you say that's not even doable I can't argue. > } You know Bart, with all the time you've spent on this, you could have > } written that HOWTO ;-) > > The problem is, I wouldn't have known what to write. > Yeah, the paradox of the expert. Experts don't know what they know. The best writer is the guy who just learned it so he remembers what he needed to learn, where he went wrong, what was important, what was distraction. Then the expert edits it for factuality. Once four or five learners have added their lessons to the doc, it becomes really usable for the next guy. Like the best wikis. The less of an expert you are, the better judge you are as to the usefulness of a doc.