From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4981 invoked by alias); 2 Jan 2015 20:15: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: 34079 Received: (qmail 8839 invoked from network); 2 Jan 2015 20:15:15 -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=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 X-Originating-IP: [86.6.153.127] X-Spam: 0 X-Authority: v=2.1 cv=AoZg3YNP c=1 sm=1 tr=0 a=39NrsSuza2clQiZR/7fYWQ==:117 a=39NrsSuza2clQiZR/7fYWQ==:17 a=kj9zAlcOel0A:10 a=NLZqzBF-AAAA:8 a=q2GGsy2AAAAA:8 a=wEplAbjyU4oXVPkEBsoA:9 a=CjuIK1q_8ugA:10 a=Cm_aIUlu_O0A:10 a=5_73CXlOpmgA:10 Date: Fri, 2 Jan 2015 20:15:10 +0000 From: Peter Stephenson To: zsh-workers@zsh.org Subject: Re: [PATCH] ERR_EXIT with "for" loops and shell functions (Re: Bug report) Message-ID: <20150102201510.2a022046@ntlworld.com> In-Reply-To: <150102105613.ZM8621@torch.brasslantern.com> References: <20141226165344.GC1003@basilisk> <141226183516.ZM18384@torch.brasslantern.com> <141227163220.ZM11821@torch.brasslantern.com> <20150102165623.7c4e3dd1@ntlworld.com> <150102105613.ZM8621@torch.brasslantern.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Fri, 02 Jan 2015 10:56:13 -0800 Bart Schaefer wrote: > This one: > > } + set -- > } + false > } + for x; do > } + print nothing executed > } + done > } +0:Status 0 from for with implicit empty list > > Makes me wonder if my similar test of "select" needs an explicit "set --" > as well? Obviously wouldn't hurt, but the chances of extra arguments creeping into the function that's executing the test is probably fairly low. pws