37752: More tests for the previous patch.

mikachu/badarrays
Daniel Shahaf 8 years ago
parent bced1beb8c
commit 1d9c6a746c

@ -1,5 +1,8 @@
2016-01-29 Daniel Shahaf <d.s@daniel.shahaf.name>
* 37752: Test/D04parameter.ztst: More tests for the previous
patch.
* 37700: Src/lex.c, Src/parse.c, Src/zsh.h,
Test/D04parameter.ztst: Teach ${(z)} the 'repeat WORD SUBLIST'
syntax.

@ -481,6 +481,9 @@
'((0.25542 * 60) - 15)*60'
'repeat 3 (x)'
'repeat 3 (echo foo; echo bar)'
'repeat $(( 2 + 4 )) (x)'
'repeat $( : foo bar; echo 4) (x)'
'repeat "1"'\''2'\''$(( 3 + 0 ))$((echo 4);)\ 5 (x)'
)
for string in $strings; do
array=(${(z)string})
@ -530,6 +533,21 @@
>7:echo:
>8:bar:
>9:):
>1:repeat:
>2:$(( 2 + 4 )):
>3:(:
>4:x:
>5:):
>1:repeat:
>2:$( : foo bar; echo 4):
>3:(:
>4:x:
>5:):
>1:repeat:
>2:"1"'2'$(( 3 + 0 ))$((echo 4);)\ 5:
>3:(:
>4:x:
>5:):
line=$'A line with # someone\'s comment\nanother line # (1 more\nanother one'

Loading…
Cancel
Save