From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11336 invoked by alias); 8 Jan 2011 22:29:17 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 28601 Received: (qmail 10308 invoked from network); 8 Jan 2011 22:29:14 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received-SPF: pass (ns1.primenet.com.au: SPF record at ntlworld.com designates 81.103.221.47 as permitted sender) Date: Sat, 8 Jan 2011 22:29:02 +0000 From: Peter Stephenson To: zsh-workers@zsh.org Subject: Re: exec -a and parameter expansion Message-ID: <20110108222902.67a13bd2@pws-pc.ntlworld.com> In-Reply-To: <20110108215239.059062c3@pws-pc.ntlworld.com> References: <8739p4wekt.fsf@gmail.com> <20110107225616.GA99800@redoubt.spodhuis.org> <110107181708.ZM628@torch.brasslantern.com> <20110108215239.059062c3@pws-pc.ntlworld.com> X-Mailer: Claws Mail 3.7.8 (GTK+ 2.22.0; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Cloudmark-Analysis: v=1.1 cv=R50lirqlHffDPPkwUlkuVa99MrvKdVWo//yz83qex8g= c=1 sm=0 a=vDwptv0gWgwA:10 a=kj9zAlcOel0A:10 a=NLZqzBF-AAAA:8 a=lx3sG5xHVHSDmDkIFRAA:9 a=HJbkeLzhBgyOgwdJcXQA:7 a=MLkrlHcaCR3EwOXh0gKU0iUPQ0QA:4 a=CjuIK1q_8ugA:10 a=_dQi-Dcv4p4A:10 a=HpAAvcLHHh0Zw7uRqdWCyQ==:117 On Sat, 8 Jan 2011 21:52:39 +0000 Peter Stephenson wrote: > There was some discussion of the KSH_TYPESET behaviour on the Austin > group list; I can't remember the exact upshot, but it's possible it > makes the proposed change a requirement. To litter the world with yet more emails: I think (but am too lazy to check) it might have been worse and and you were expected to handle: t=typeset $t foo=`echo one two` such that foo was assigned the value "one two". In other words, you have to expand the first word separately, remember which words you produced (because it might have been more than one), check if the first word is now typeset or a variant, then expand the words you haven't yet expanded taking that into account. This procedure is nicely covered by the English slang word, 'ick'. Neither bash nor ksh currently does this either, however, they behave the same as zsh with KSH_TYPESET and SH_WORD_SPLIT. -- Peter Stephenson Web page now at http://homepage.ntlworld.com/p.w.stephenson/