From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13892 invoked by alias); 8 Feb 2010 17:42:59 -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: 27691 Received: (qmail 6652 invoked from network); 8 Feb 2010 17:42:58 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.5 Received-SPF: none (ns1.primenet.com.au: domain at closedmail.com does not designate permitted sender hosts) From: Bart Schaefer Message-id: <100208094242.ZM10754@torch.brasslantern.com> Date: Mon, 08 Feb 2010 09:42:41 -0800 In-reply-to: <237967ef1002080916w5fea886bi888a087ea62fc9cb@mail.gmail.com> Comments: In reply to Mikael Magnusson "Re: extra arguments inserted by glob thinger e:: get sorted afterwards" (Feb 8, 6:16pm) References: <237967ef1002050715o3be2d441rcc8dbeb3e2b00483@mail.gmail.com> <87ljf3yk0f.fsf@ft.bewatermyfriend.org> <237967ef1002080916w5fea886bi888a087ea62fc9cb@mail.gmail.com> X-Mailer: OpenZMail Classic (0.9.2 24April2005) To: zsh-workers@zsh.org Subject: Re: extra arguments inserted by glob thinger e:: get sorted afterwards MIME-version: 1.0 Content-type: text/plain; charset=us-ascii On Feb 8, 6:16pm, Mikael Magnusson wrote: } } As an aside, is "$(echo a b c)" the only way to get an 'inline' array } in a ${} expression? The most obvious is ${=:-one two three} which applies word splitting to the string to the right of the hyphen. Interestingly this even works with quoting, where I had assumed it would break within words: zsh% print -l ${=:-"one two" three\ four 'five six'} one two three four five six And you can combine it with rcexpandparam: zsh% print -l X${^=:-"one two" three\ four 'five six'}Z Xone twoZ Xthree fourZ Xfive sixZ --