[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: functions can fully unset local vars in other scopes

From: Chet Ramey
Subject: Re: functions can fully unset local vars in other scopes
Date: Mon, 1 Aug 2022 09:58:46 -0400
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.11.0

On 7/30/22 8:05 AM, Kerin Millar wrote:

What consideration was given to creating “local --unset *VAR*” or “unset
--local *VAR*” or some other equivalent that doesn't overload any existing
command form?

Obviously, only Chet can meaningfully respond to this. I mentioned the 
existence of the option because it appeared likely that Emanuele was unaware of 
it, not to attempt to obviate any of his suggestions, nor endorse the status 

Sometimes it's useful to read the discussion that prompted the change.


In this case, the primary requirement was to enable scripts that wanted a
wholesale behavior change, while not breaking backwards compatibility by
making that option the default. Enabling these semantics on a per-variable
basis wasn't part of the discussion (kre was, however, very vocal about
making localvar_unset the default).

``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://tiswww.cwru.edu/~chet/

reply via email to

[Prev in Thread] Current Thread [Next in Thread]