Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: LOCAL_VARS option ?
- X-seq: zsh-workers 40385
- From: Jens Elkner <jel+zsh@xxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Re: LOCAL_VARS option ?
- Date: Thu, 19 Jan 2017 10:43:07 +0100
- In-reply-to: <20170119065408.GA5534@fujitsu.shahaf.local2>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mail-followup-to: zsh-workers@xxxxxxx
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <20170119065408.GA5534@fujitsu.shahaf.local2>
On Thu, Jan 19, 2017 at 06:54:08AM +0000, Daniel Shahaf wrote:
> Phil suggested on IRC a LOCAL_VARS option that has the effect of making
> all newly-declared variables local; e.g.,
Hmmm, I like the implicit way ksh93 does it, i.e. if declared within a
"function $fname {...}" declared function using 'typeset', it has local
scope, otherwise (i.e. not typeset or typeset in "$fname() { ... }" aka
old style declared functions) shared. Not sure, whether this can be
accomplished with zsh as well ...
have fun,
jel.
--
Otto-von-Guericke University http://www.cs.uni-magdeburg.de/
Department of Computer Science Geb. 29 R 027, Universitaetsplatz 2
39106 Magdeburg, Germany Tel: +49 391 67 52768
Messages sorted by:
Reverse Date,
Date,
Thread,
Author