[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Behaviour of test -v with assoc array and quote character in key
From: |
Greg Wooledge |
Subject: |
Re: Behaviour of test -v with assoc array and quote character in key |
Date: |
Tue, 23 Feb 2021 08:32:40 -0500 |
User-agent: |
Mutt/1.10.1 (2018-07-13) |
On Tue, Feb 23, 2021 at 02:03:30PM +0100, Léa Gris wrote:
> (
> LANG=C
> unset var assoc
> var=\'\]
> declare -Ai assoc
> assoc[$var]=1
> assoc[$var]+=1
> ((assoc['$var']++))
> typeset -p assoc
> )
This "works" in bash 5.0 but not in Debian's bash 5.1. The -i flag is
irrelevant as well -- I get the same results with or without it (for
the command with (( )) in it).
- Behaviour of test -v with assoc array and quote character in key, Daniel Gröber, 2021/02/14
- Re: Behaviour of test -v with assoc array and quote character in key, Greg Wooledge, 2021/02/15
- Re: Behaviour of test -v with assoc array and quote character in key, Chet Ramey, 2021/02/15
- Re: Behaviour of test -v with assoc array and quote character in key, Andreas Schwab, 2021/02/23
- Re: Behaviour of test -v with assoc array and quote character in key, Greg Wooledge, 2021/02/23
- Re: Behaviour of test -v with assoc array and quote character in key, Oğuz, 2021/02/23
- Re: Behaviour of test -v with assoc array and quote character in key, Greg Wooledge, 2021/02/23
- Re: Behaviour of test -v with assoc array and quote character in key, Oğuz, 2021/02/23
- Re: Behaviour of test -v with assoc array and quote character in key, Chet Ramey, 2021/02/23