From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 701 invoked by alias); 19 Aug 2015 00:25: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: 36235 Received: (qmail 26707 invoked from network); 19 Aug 2015 00:25:26 -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=-1.9 required=5.0 tests=BAYES_00 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:in-reply-to:comments :references:to:subject:mime-version:content-type; bh=RlNvzlpCptvnll2gvie2vSMfIdpJHt0Hc8BzKiqx5w8=; b=d51ueTlJeTVLAn+4FMSU3IDvozUx3pzDtOYPtVairI4VH2CyVHdfoiv0INXkKBiGPd REpuoNAMHi4tIMvQit+hL1NM87hn4raw/gprjncUsHfWp+TRI1xFeNmDv1uDW8nLyrKD yAyIsWDVdCObnz6Gx08mNMIjh8xx3t72MANMyZu3ssXsi/wYO49JwPgVmHNzVTuNXrr5 COjfS59wz3YziLjpq9OJ/8xU8O0ij7hP3PmJqeRBMDYFnheKwWz+DDGLubGzZUgssB6a nvcccQPbZOln4iGii3s87eJv8Vg5c5/iv9542ElkhyGg/bwkt1K6Qd242UJEqBg4MWDe 31oQ== X-Gm-Message-State: ALoCoQl9ZW6UCzlY6nqNnmtUuwqxgzA8MH79rYMdMoxLlx1cjjEwgIQBU6wXtTSBt89Ba9RD+5Ts X-Received: by 10.60.84.164 with SMTP id a4mr5864207oez.63.1439943922730; Tue, 18 Aug 2015 17:25:22 -0700 (PDT) From: Bart Schaefer Message-Id: <150818172517.ZM31990@torch.brasslantern.com> Date: Tue, 18 Aug 2015 17:25:17 -0700 In-Reply-To: <20150819000649.GA29640@zira.vinc17.org> Comments: In reply to Vincent Lefevre "Re: PRINT_EXIT_VALUE: Suppress for if/while conditions" (Aug 19, 2:06am) References: <20150731231225.GB2054@tarsus.local2> <20150815010451.GA16635@ioooi.vinc17.net> <20150819000649.GA29640@zira.vinc17.org> X-Mailer: OpenZMail Classic (0.9.2 24April2005) To: zsh-workers@zsh.org Subject: Re: PRINT_EXIT_VALUE: Suppress for if/while conditions MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii On Aug 19, 2:06am, Vincent Lefevre wrote: } Subject: Re: PRINT_EXIT_VALUE: Suppress for if/while conditions } } > for i in file1 file2; do } > veryimportanttask $i } > done } } But you don't know which one: } } $ for i in 1 2; do /bin/false $i; done } zsh: exit 1 /bin/false $i } zsh: exit 1 /bin/false $i eval "veryimportanttask ${(b)i}" Of course then printexitvalue prints "exit 1" for each of the eval as well. *There* is a case where it's probably entirely extraneous. torch% setopt printexitvalue torch% for i in 1 2; do eval /bin/false $i; done zsh: exit 1 /bin/false 1 zsh: exit 1 zsh: exit 1 /bin/false 2 zsh: exit 1