1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-09-02 22:11:54 +02:00

33459: test for variable substitution in variable splitting

This commit is contained in:
Peter Stephenson 2014-10-13 11:38:48 +01:00
parent 03241e50b0
commit 66320ca93a
2 changed files with 25 additions and 0 deletions

View file

@ -1,3 +1,8 @@
2014-10-13 Peter Stephenson <p.stephenson@samsung.com>
* 33459: Test/D04parameter.ztst: test for variable substitution
in variable splitting.
2014-10-13 Oliver Kiddle <opk@zsh.org>
* 33438: Completion/Base/Utility/_sequence: use the new way of

View file

@ -1636,3 +1636,23 @@
print ${noexist:^foo})
1:Zipping arrays, NO_UNSET part 2
?(eval):2: noexist: parameter not set
expr="a@b,c@d:e@f,g@h:i@j,k@l"
for sep in : , @; do
print -l ${(ps.$sep.)expr}
done
0:Use of variable to get separator when splitting parameter
>a@b,c@d
>e@f,g@h
>i@j,k@l
>a@b
>c@d:e@f
>g@h:i@j
>k@l
>a
>b,c
>d:e
>f,g
>h:i
>j,k
>l