bug-bash
[Top][All Lists]
Advanced

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

Re: incorrect associative array key parsing if they contain closing squa


From: Chet Ramey
Subject: Re: incorrect associative array key parsing if they contain closing square bracket
Date: Sun, 29 May 2011 14:16:59 -0400

> associative array key parsing seems to be incorrect if they contain 
> closing square bracket inside the array=([key]=value) construct.
> 
> the following testcase :
> 
> $ declare -A key_full; key_full=(["version[agent]"]=agent.version); echo 
> "${!key_full[@]}"

Yes, this is a problem.  Thanks for the report.  As a workaround,

key_full["version[agent]"]=agent.version

works correctly.

Chet

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



reply via email to

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