From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3638 invoked by alias); 19 Dec 2014 06:05:29 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 19598 Received: (qmail 15310 invoked from network); 19 Dec 2014 06:05:29 -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-CMAE-Score: 0 X-CMAE-Analysis: v=2.1 cv=D9vw8UVm c=1 sm=1 tr=0 a=FT8er97JFeGWzr5TCOCO5w==:117 a=kj9zAlcOel0A:10 a=q2GGsy2AAAAA:8 a=oR5dmqMzAAAA:8 a=-9mUelKeXuEA:10 a=A92cGCtB03wA:10 a=iZO1BlGHIjCZ_q0b9wgA:9 a=CjuIK1q_8ugA:10 From: Bart Schaefer Message-id: <141218220556.ZM28901@torch.brasslantern.com> Date: Thu, 18 Dec 2014 22:05:56 -0800 In-reply-to: Comments: In reply to Kurtis Rader "Re: Could someone clarify how math functions work?" (Dec 18, 9:48pm) References: <54939F50.50102@gmx.com> <141218213450.ZM28822@torch.brasslantern.com> X-Mailer: OpenZMail Classic (0.9.2 24April2005) To: Zsh Users Subject: Re: Could someone clarify how math functions work? MIME-version: 1.0 Content-type: text/plain; charset=us-ascii On Dec 18, 9:48pm, Kurtis Rader wrote: } } Your second example is identical to the first so you apparently did what I } often do: forgot to make a copy of the desired text. That is, your second } example should be } } zsh -c 'add() { for arg; do (( n += arg )); done; print n: $n }; functions } -M add; print results: $(( add(3,1,2) ))' That IS what my second example is; look again at the text you excerpted (not copied again here). By the way, though I personally don't care much any more after too many years of arguing, we try to discourage "top posting" on these lists. } I would argue that your explanation, while correct, illustrates my point. No disagreement, but what is the point of making that point, again? Jut to tell Eric to go program in something else? -- Barton E. Schaefer