From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4030 invoked by alias); 14 Jan 2017 19:51:14 -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: 22384 Received: (qmail 4615 invoked from network); 14 Jan 2017 19:51:14 -0000 X-Qmail-Scanner-Diagnostics: from mta03.eastlink.ca by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(24.224.136.9):SA:0(-3.9/5.0):. Processed in 1.050376 secs); 14 Jan 2017 19:51:14 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-3.9 required=5.0 tests=RCVD_IN_DNSWL_LOW, RP_MATCHES_RCVD,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.1 X-Envelope-From: rayandrews@eastlink.ca X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at _spf.eastlink.ca designates 24.224.136.9 as permitted sender) X-Authority-Analysis: v=2.2 cv=DOfN2GFb c=1 sm=1 tr=0 a=28Ntk8jg+Dho8ABWn/CRtA==:117 a=28Ntk8jg+Dho8ABWn/CRtA==:17 a=N659UExz7-8A:10 a=tu8u0aYpQm7YCZpXj9oA:9 a=pILNOxqGKmIA:10 X-EL-IP-NOAUTH: 24.207.16.108 Subject: Re: whence question To: zsh-users@zsh.org References: <652bcc3f-7365-2e52-d39c-8576278606bc__74.9235078275845$1484367323$gmane$org@eastlink.ca> <20170114044044.GA4002@fujitsu.shahaf.local2> <4981e434-473a-4dca-5d03-fea2e3051c1b@eastlink.ca> <63d2b432-4ca9-0e85-014c-333cb0f46836@eastlink.ca> From: Ray Andrews Message-id: Date: Sat, 14 Jan 2017 11:51:08 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Icedove/45.4.0 MIME-version: 1.0 In-reply-to: Content-type: text/plain; charset=windows-1252; format=flowed Content-transfer-encoding: 7bit On 14/01/17 10:55 AM, Bart Schaefer wrote: > > local _args=( ${~@} ) > > Well nuts. I use what seems to work and if there's a better way that I don't know about, then I don't know about it until I know about it. I thought I learned that whenever 'nogob' was in effect that 'eval' was the only way to crack open a glob! I've always hated it, so the above seems a huge improvement unless there's any gotchas with it. So hard to really understand these myriads of syntactic tricks. I'm still most of the time trying things by trial and error and saved snips of things that seemed to work elsewhere. Real mastery is still some time off. What would be useful is a sort of 'walk through' of some constructions so that the parse becomes human understandable. Above I'd read: the local variable '_args' will be created as an array (split on God know what) set equal to the contents of the argument string (modified by the tilde in some way that I've never seen), the argument string being enclosed in '${}' because it is being modified ... so I almost read that one.