From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 28860 invoked from network); 2 Dec 2020 17:19:23 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 2 Dec 2020 17:19:23 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1606929563; b=ZFZw0/vNUmtXbJbH/wwJ2O6Fa8BlHoCzyR/kc1fKNj8vq3t5S1ZH0O7uCmJ46vQIpgwDwzxQqr uGc52YzSi4zLuFPgOWgrcicB0gD9OwsLpNUb/+GClsAs3Lg26Stuokcv0At07SY7M3f0I8piKU fc9gKSTnGwBgQbq7sxnuU5QhqG4gbFuA1oiO+Ei8Fs3hqBkw/MP/DyHi9ugnKPbPCrHm+9OULn oaGPlDGcTb0e6LH7W/IFmaFhofqA47trX70wnGzdIvHYMbyp/eVunLoXWxDJg4rdHSSalLTTbs +pZ3TA7MsmN41co7rNoMoTp2NI77kETC7cLAarwlaUfGbQ==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (joooj.vinc17.net) smtp.remote-ip=155.133.131.76; dmarc=none header.from=vinc17.net; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1606929563; bh=eqGYMH1QNlisIa7E9b89I10WSNcL+rbLvg5b/+BLrvw=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:In-Reply-To:Content-Transfer-Encoding:Content-Type: MIME-Version:References:Message-ID:Subject:To:From:Date:DKIM-Signature; b=ccL7BDe7bcxBUe0yFrxchibb6ekS4bSSudon5GAc1sZMRnNugackZPPI5LLfuePjk3EhlugxWT wIUWOsk/5HYKTYxVsJoeykeCFxpGeJOuqy8pa8yjVDCn3qFIwq+Jz1P149Ew4lF0OS95ZWQGhC XlEGiQXkP6e9AzA48g3xidO56hDUqEejIfl5uiG1dxxI2zNlbCT24BAXAL51g4M1abfvooXGr5 AAH7FoonLAnWp0MhNWYRWpRCII5IQogF8fjmYpUbVcU2LLS6GyQgJQ8rsVrbSLIaLkZQamzsQq UlBGvzBNhGpeX3PmPxE6mfJoXBomrDVSJQjCVf9GfClZZg==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20200801; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:In-Reply-To:Content-Transfer-Encoding :Content-Type:MIME-Version:References:Message-ID:Subject:To:From:Date: Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=fcNVCJOA7M15VUit2/pntmzGcO8rOL/W+ed8HdKPNSc=; b=eginmz//tO4Oeq6Z3vklGDuSMu B7rX+sjYCoqG7IWqCnAi+16Y5yip71OYn2+Bfxj2B5mt2jIOibpPnW5T+dO22ku4xYFtO2LMFoYqP AM+Mk4nJWwPNA24usPcaUfGn40o6cmZ3b6FGOL9rudpjqqHHL3/txGdJdQbKXAh38C7zI+iILTqRa AkwQ+VpsJV4N5i2dz+m3acM716Mjq+pCe93g/3IKerJqTp66qjS3mFLlIWlctFmxTZTmKxG6dThv9 XAvxrB/MlE4jsZSnq+FyeO5CwQHhYzySwvcgGBQ7nyDCoC3z+3yUXYu9+cdZABEaI3Bq04RONzQGx QJClQlLQ==; Received: from authenticated user by zero.zsh.org with local id 1kkVmi-000Gc9-Kv; Wed, 02 Dec 2020 17:19:20 +0000 Authentication-Results: zsh.org; iprev=pass (joooj.vinc17.net) smtp.remote-ip=155.133.131.76; dmarc=none header.from=vinc17.net; arc=none Received: from joooj.vinc17.net ([155.133.131.76]:57550) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_256_GCM_SHA384:256) id 1kkVmO-000GSN-OL; Wed, 02 Dec 2020 17:19:01 +0000 Received: from smtp-zira.vinc17.net (128.119.75.86.rev.sfr.net [86.75.119.128]) by joooj.vinc17.net (Postfix) with ESMTPSA id 8937FA4F; Wed, 2 Dec 2020 18:18:59 +0100 (CET) Received: by zira.vinc17.org (Postfix, from userid 1000) id 43927C20624; Wed, 2 Dec 2020 18:18:59 +0100 (CET) Date: Wed, 2 Dec 2020 18:18:59 +0100 From: Vincent Lefevre To: zsh-workers@zsh.org Subject: Re: One possible answer to typeset vs. unset Message-ID: Mail-Followup-To: zsh-workers@zsh.org References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Mailer-Info: https://www.vinc17.net/mutt/ User-Agent: Mutt/2.0.2+26 (1ec642e2) vl-132933 (2020-12-01) X-Seq: 47712 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: Archived-At: On 2020-11-28 11:49:12 -0800, Bart Schaefer wrote: > The typeset -AEFHLRTZailux options are applied upon the first > assignment to the variable. Explicit unset before the first assignment > discards all of those properties. If any option is applied to an > existing name, historic behavior is unchanged. OK for the second sentence (about unset), but I don't understand the first sentence. Could you explain the following behavior? zira% ./zsh -c 'typeset -i x; echo $x; echo $((x+3)); unset x; echo $((x+3));' 3 3 zira% ./zsh -c 'typeset -E x; echo $x; echo $((x+3)); unset x; echo $((x+3));' 3. 3 zira% Why do I get "3." if the -E option isn't supposed to be applied yet? -- Vincent Lefèvre - Web: 100% accessible validated (X)HTML - Blog: Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)