From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13380 invoked by alias); 14 Feb 2016 10:04:28 -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: 37963 Received: (qmail 24147 invoked from network); 14 Feb 2016 10:04:26 -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=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=EQfMUuJQZfPhabn4PYGp8zfDfieaZY2EM41DrIMxCUk=; b=pY7lKlqO8gw0+dfaDgovqVb9GQ+dNBRHQ4Xb/WyC71/g7WBsU19ZYXN0AguCiKaePT 8TToRc1bgYvqgfbdGxpQI64zvhP1kb/566SXCAnNTB9Il8wipttXNbC/gGzaF9h5CqpV gwSYCZwpxmX7IawdNiXsEkt1Su3xJIgNV7A/UBCKS1Ar7/dqxORhahYb3ZkpePsTiNlC iLKEL1JSUU3QcLsCQnnQqcpL9zzwAyj5bNWCUSotZTmBytuyjqdwsSveAN93nRtQZV83 HWJAGlJy3ALhCLhVMIC37Y8hPsZjbQAygZ0SApZZB9fKv3eQbXI7fdDZxSH8Bm6ssY08 5yHw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=EQfMUuJQZfPhabn4PYGp8zfDfieaZY2EM41DrIMxCUk=; b=VG0CNcd6z71o+1v5wcGVRCyqVYjgYsV7wseNmlbmkZKdOdJEEkJrM+mNU2ekwljcw/ XPCM9gCFMDWQcMdJZsDY4FQW0KbSvFQtKM7MvmvWPy3oEW5gFlxUTxQMegfoi1l8/97L xeACy8+gprWLXKC3JPtcidkRKSRqxr96XL0jTyr4JXLziQ23Ts6xPR1bgtdsMV2Q23L+ +RyCs472C0RdcT941MtSYydYMEzGKO/zwGVHCjLhF6WcgBJXkBc51DA2CdjrHZ+YjwB3 AM/1zSGSf9TZp+K6ahLzttGD0/AvnJ2Tmw5GdYMNsNMXkYYKuYUw2/GTiO/EQw3K5+r/ XZNw== X-Gm-Message-State: AG10YORrPa+PnC/jFXI17vmGPOQumrnhUD5CiRojS740NkzZ40tkXPO6qvdJKWi6sb0GCKLfjYF+qb005wwoFw== X-Received: by 10.25.151.149 with SMTP id z143mr1535646lfd.72.1455444262323; Sun, 14 Feb 2016 02:04:22 -0800 (PST) MIME-Version: 1.0 In-Reply-To: <160205091543.ZM29723@torch.brasslantern.com> References: <160205091543.ZM29723@torch.brasslantern.com> From: Sebastian Gniazdowski Date: Sun, 14 Feb 2016 11:04:02 +0100 Message-ID: Subject: Re: Should (t)path = array-unique-special work this way To: Bart Schaefer Cc: Zsh hackers list Content-Type: text/plain; charset=UTF-8 On 5 February 2016 at 18:15, Bart Schaefer wrote: > > Q: Why doesn't -U appear in the "declare -p" output? > A: Good question. It doesn't appear for non-special arrays either. It > may be intentional because -U isn't a POSIX-supported option, but I > suspect it's just an accidental omission. Wanted to write a snapshot feature, basically declare -p > snapshot; setopt typesetsilent; source ./snapshot, but the omission of -U is quite a blocker. Other interesting thing is that typeset -a a doesn't fully redefine a, uniqueness still holds if it was present. % typeset -Ua a % a=( a a ) % echo ${a[@]} a % declare -p > snapshot % source ./snapshot % a=( a a ) % echo ${a[@]} a % echo ${(t)a} array-unique % unset a % source ./snapshot % echo ${(t)a} array % a=( a a ) % echo ${a[@]} a a Best regards, Sebastian Gniazdowski