From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11562 invoked by alias); 6 Oct 2015 08:40:39 -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: 36801 Received: (qmail 23072 invoked from network); 6 Oct 2015 08:40:37 -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-AuditID: cbfec7f4-f79c56d0000012ee-f0-56138902b847 Date: Tue, 06 Oct 2015 09:40:31 +0100 From: Peter Stephenson To: zsh-workers@zsh.org Subject: Re: Proof of concept: "static" parameter scope Message-id: <20151006094031.65e4baf3@pwslap01u.europe.root.pri> In-reply-to: <20151005215514.GB1959@tarsus.local2> References: <150924192305.ZM2680@torch.brasslantern.com> <20150925101540.5d2ded9c@pwslap01u.europe.root.pri> <20150930203825.307d3f8f@ntlworld.com> <150930172748.ZM3986@torch.brasslantern.com> <20151003201936.29b52aa4@ntlworld.com> <20151005215514.GB1959@tarsus.local2> Organization: Samsung Cambridge Solution Centre X-Mailer: Claws Mail 3.7.9 (GTK+ 2.22.0; i386-redhat-linux-gnu) MIME-version: 1.0 Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7bit X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrKLMWRmVeSWpSXmKPExsVy+t/xy7pMncJhBku6+CwONj9kcmD0WHXw A1MAYxSXTUpqTmZZapG+XQJXxrlvC5gKzrNV9Oy+wNbAOIO1i5GTQ0LARKLh2zFGCFtM4sK9 9WxdjFwcQgJLGSUmthxggnBmMEk8ejuLFcLZyihxf+IFFpAWFgFViYtdvcwgNpuAocTUTbPB RokIiEucXXserEZYwFzi0eI5YOt4BewlZnzcCVbPKWAk8Xz1IaihU5kkXq1bAtbAL6AvcfXv JyaIm+wlZl45wwjRLCjxY/I9sBpmAS2JzduaWCFseYnNa96CDRUSUJe4cXc3+wRGoVlIWmYh aZmFpGUBI/MqRtHU0uSC4qT0XEO94sTc4tK8dL3k/NxNjJDA/bKDcfExq0OMAhyMSjy8EjeF woRYE8uKK3MPMUpwMCuJ8P7kEg4T4k1JrKxKLcqPLyrNSS0+xCjNwaIkzjt31/sQIYH0xJLU 7NTUgtQimCwTB6dUA6PAvsfi80RO7ma9MdXPPF/EY8fCzpCUCW8mzegvuXO2y/W9Ucbk9nWa /LazHdMlFn+WsLl787nXrUer5+1V2xu1NNH81nPxlQyJs8Q9ps84d1T8c8GPZ5lmJoFHNz/6 lqzeHh2nZByvXXhwwd0JSrPuWdvPabzlxrPq9Ypp3D/WX15gdphh3ZJtSizFGYmGWsxFxYkA oElaclgCAAA= On Mon, 5 Oct 2015 21:55:14 +0000 Daniel Shahaf wrote: > % disable -r local > % zxxx() { local x=(a b c); print $x } > % enable -r local > % which zxxx > zxxx () { > local x=(a b c) > print $x > } > > Should it output 'builtin local x=(a b c)'? There's also the opposite case of loading some standard functions with the full interface and disabling it to run some stuff of your own in compatibility mode, for which there's no obvous fix without outputting an "enable" (and hoping the user hasn't disabled enable to get the printer control command...) I'm not sure it's worth a code fix, though a well-placed note might be useful. pws -- Peter Stephenson | Principal Engineer Samsung Cambridge Solution Centre Email: p.stephenson@samsung.com | Phone: +44 1223 434724 | www.samsung.com