[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: test -v and environment variable names with subscripts
From: |
Chet Ramey |
Subject: |
Re: test -v and environment variable names with subscripts |
Date: |
Wed, 18 Jul 2018 15:50:09 -0400 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 |
On 7/17/18 5:19 PM, Grisha Levit wrote:
> When there is a variable with a name that includes a subscript in the
> environment, test -v looks at that variable rather than an array with
> that subscript.
Even though bash needs to do a better job to segregate environment
variables with invalid names, there are a couple of changes I can
make to the test -v code to improve it, too.
Chet
--
``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/