From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9268 invoked by alias); 3 Jul 2014 07:43:27 -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: 32830 Received: (qmail 15326 invoked from network); 3 Jul 2014 07:43:26 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=secretsauce.net; h=from:to:subject:date:message-id:mime-version:content-type; s= mesmtp; bh=9Z/k/knQHRoT+avpLyvMaamHqvw=; b=D9ejPdU9LJrOX0DF3Rgdr 64se/SyJ0N+niqV9vHfHeQehG9FeKGm7MJoLox8pq6jF2cYFhiQO/p/i1WTf2k3v 1pJsoJ8ozwSDDUgEFfMqgycL7cnuB2QZNt20fVk3Gray7OE3Mi0cxEB1sCjHboJ7 3IyeTm+PqomOCGidXNdEQU= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=from:to:subject:date:message-id :mime-version:content-type; s=smtpout; bh=9Z/k/knQHRoT+avpLyvMaa mHqvw=; b=LS3WW9GnKMf/vaCDPBbN5CreSva8RF/RWu47Acto+QlcT03FH+/7QU wVDQKEv8aB8SXDWCK/iBd8W13DfpHIlXQkDeNdr2bm+dESzPo5Ys1zboTggAvZS9 i4f4mEarPeui57fwFiW1165hbubC3wB3J4yUEFOh3B9lW+Rd7f3To= X-Sasl-enc: +UGQNDZBlcmqWdjS/VnB1rLOrw0y7uYnV5cocEPJdyTv 1404373404 User-agent: mu4e 0.9.9.6pre3; emacs 24.4.50.1 From: Dima Kogan To: zsh-workers Subject: Odd expansion behavior Date: Thu, 03 Jul 2014 00:43:23 -0700 Message-ID: <87pphm51lw.fsf@secretsauce.net> MIME-Version: 1.0 Content-Type: text/plain Hi. I'm observing something odd. It might be a bug, but I don't understand it well-enough to call it that. I see this: $ x=(1 2 3); echo xxx${^x} xxx1 xxx2 xxx3 This output makes sense. However something slightly different is strange: $ x=(1 2 3); y=xxx${^x}; echo $y xxx1 2 3 Here the ${^x} form turns on the RC_EXPAND_PARAM option, and it's apparently not kicking in in the second (broken) case. Even if I setopt it, I still don't have this working. I asked on #zsh and osse helpfully pointed out that this can be made to work by expressing the assignment as 'y=(xxx${^x})' instead, which does work. But shouldn't it work the other way as well? osse wasn't sure why the original form wasn't working, so I'm reporting it here as a maybe-bug. Thanks dima