1
0
mirror of git://git.code.sf.net/p/zsh/code synced 2024-09-14 16:10:44 +02:00

unposted: fix parsing of Bang token in value side of array element assignment

This commit is contained in:
Bart Schaefer 2024-08-15 18:06:19 -07:00
parent 8a811b369b
commit 5977d3cdd4
3 changed files with 14 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2024-08-15 Bart Schaefer <schaefer@zsh.org>
* unposted (see 53034): Src/lex.c, Test/A06assign.ztst: fix parsing
of Bang token in value side of array element assignment
2024-08-13 Eric Cook <llua@gmx.com>
* 53031: Christian Heusel: Completion/Unix/Command/_git: add

View File

@ -1402,10 +1402,11 @@ gettokstr(int c, int sub)
/*
* Same logic as Dash, for ! to perform negation in range.
*/
if (seen_brct)
if (seen_brct && brct)
c = Bang;
else
c = '!';
break;
case LX2_OTHER:
if (in_brace_param) {
if (c == '/') {

View File

@ -743,3 +743,10 @@
print $a
0:overwrite [2] character (string: "") with "xx"
>xx
( sleep 1 &
x[1]=$!
typeset -p x
)
0:regression workers/53033: assigning $! to array element
*>typeset -g -a x=\( <-> \)