From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9502 invoked by alias); 25 Jun 2015 16:21:38 -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: 35608 Received: (qmail 17912 invoked from network); 25 Jun 2015 16:21:36 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL autolearn=ham autolearn_force=no version=3.4.0 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:message-id:date:to:subject:mime-version :content-type; bh=twdCcO30LN1u8fWZ9GiL6bLzJwUFrbcLxCQ8v9z4VlE=; b=RX9Z9DUitZbIEg8PYD7JNh3X/dt9+WohXs1yHFWd7u3KxdIoll0jDqEjEtnNdgDOdS UTyq+IpPbmK1KFvyHKHmZ+JttxAIv8bGpjtLsvmoLL+gGG0kxX3Rj+PdedbFzlB+1dm5 e/L4ZjVqIUxf5jTetpHIUEQLKzWx8n49gno1nQM72BOQN2jPISmMBZ2rCHBmAeYW0Txf XkMtMCVlXaxKmvh4uJER71Nbvj6yIJ+E/FS1IpNjKfPtwemEfejgn5UCdyfkvjN9tyZ8 qMH4rQMlPK9Di9pEQHO5ucaPSrRHvlPjcJFn7NmPGtAqvzEosRRnEbG3CXg+sPp+mNyr b5ng== X-Gm-Message-State: ALoCoQldl+mT/HpQ1PRqC60CjcWZfT/71dRmsZ6x6wd1kwF5ZO+Eq6BA61ZJUjujpzg79vZlaAAR X-Received: by 10.182.112.138 with SMTP id iq10mr30762438obb.38.1435249295085; Thu, 25 Jun 2015 09:21:35 -0700 (PDT) From: Bart Schaefer Message-Id: <150625092131.ZM20413@torch.brasslantern.com> Date: Thu, 25 Jun 2015 09:21:31 -0700 X-Mailer: OpenZMail Classic (0.9.2 24April2005) To: zsh-workers@zsh.org Subject: New typeset is a bit too verbose, and skips some assignments MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii torch% typeset x=() torch% typeset x=() x[2]=a x[4]=b x=() torch% typeset -p x typeset -a x x=('' a '' b) torch% The value of x should not have been displayed by the second typeset in that example, because all the names have assignments. It also looks wrong, because it's the value from before the assignments to elements. This only happens if the type is array before the new assignment, but the initial empty assignment doesn't have any effect: torch% typeset y torch% typeset y=() y[2]=a y[4]=b torch% typeset y=() y[1]=x y[3]=z y=('' a '' b) torch% typeset -p y y=(x a z b) torch% I expected y=(x '' z '').