mirror of
https://https.git.savannah.gnu.org/git/bash.git
synced 2026-07-03 02:10:50 +02:00
first set of changes to eliminate array subscript double expansion in math contexts
This commit is contained in:
+7
-10
@@ -520,13 +520,11 @@ argv[1] = <y>
|
||||
<X> <X> <X> <X>
|
||||
./array23.sub: line 22: $( echo >&2 foo ) : syntax error: operand expected (error token is "$( echo >&2 foo ) ")
|
||||
./array23.sub: line 23: $( echo >&2 foo ) : syntax error: operand expected (error token is "$( echo >&2 foo ) ")
|
||||
foo
|
||||
0
|
||||
foo
|
||||
foo
|
||||
foo
|
||||
6
|
||||
./array23.sub: line 34: $( echo >&2 foo ): syntax error: operand expected (error token is "$( echo >&2 foo )")
|
||||
./array23.sub: line 24: $( echo >&2 foo ) : syntax error: operand expected (error token is "$( echo >&2 foo ) ")
|
||||
./array23.sub: line 26: $( echo >&2 foo ) : syntax error: operand expected (error token is "$( echo >&2 foo ) ")
|
||||
./array23.sub: line 30: $( echo >&2 foo ): syntax error: operand expected (error token is "$( echo >&2 foo )")
|
||||
./array23.sub: line 33: $( echo >&2 foo ): syntax error: operand expected (error token is "$( echo >&2 foo )")
|
||||
./array23.sub: line 34: $index: syntax error: operand expected (error token is "$index")
|
||||
./array23.sub: line 35: $( echo >&2 foo ): syntax error: operand expected (error token is "$( echo >&2 foo )")
|
||||
0
|
||||
0
|
||||
@@ -743,10 +741,9 @@ argv[1] = <b>
|
||||
argv[2] = <a>
|
||||
argv[1] = <b+a>
|
||||
7
|
||||
./array27.sub: line 24: a[]]=7 : syntax error: invalid arithmetic operator (error token is "]=7 ")
|
||||
7
|
||||
declare -A A=([$'\t']="2" [" "]="2" )
|
||||
./array27.sub: line 36: ((: A[]]=2 : syntax error: invalid arithmetic operator (error token is "]=2 ")
|
||||
declare -A A=([$'\t']="2" ["*"]="2" [" "]="2" ["@"]="2" )
|
||||
declare -A A=([$'\t']="2" ["*"]="2" [" "]="2" ["]"]="2" ["@"]="2" )
|
||||
declare -A A=([$'\t']="2" ["*"]="2" [" "]="2" ["]"]="2" ["@"]="2" )
|
||||
./array27.sub: line 52: A[]]: bad array subscript
|
||||
declare -A A=([$'\t']="X" ["*"]="X" [" "]="X" ["@"]="X" )
|
||||
|
||||
Reference in New Issue
Block a user