summaryrefslogtreecommitdiffstats
path: root/Test/D04parameter.ztst
diff options
context:
space:
mode:
authorPeter Stephenson <pws@users.sourceforge.net>2008-03-08 01:20:49 +0000
committerPeter Stephenson <pws@users.sourceforge.net>2008-03-08 01:20:49 +0000
commit25413054c11fc4b67284d4d6db48272182da1d26 (patch)
tree7a7e7a187e8c505d531e1f5d354f846b24de646a /Test/D04parameter.ztst
parentusers/12699: don't complete normal arguments where we're completing the (diff)
downloadzsh-25413054c11fc4b67284d4d6db48272182da1d26.tar
zsh-25413054c11fc4b67284d4d6db48272182da1d26.tar.gz
zsh-25413054c11fc4b67284d4d6db48272182da1d26.tar.bz2
zsh-25413054c11fc4b67284d4d6db48272182da1d26.tar.lz
zsh-25413054c11fc4b67284d4d6db48272182da1d26.tar.xz
zsh-25413054c11fc4b67284d4d6db48272182da1d26.tar.zst
zsh-25413054c11fc4b67284d4d6db48272182da1d26.zip
24699: bug with ${(Q)...} on initial ">"
bug with ${(z)...} on string with unterminated "("
Diffstat (limited to 'Test/D04parameter.ztst')
-rw-r--r--Test/D04parameter.ztst28
1 files changed, 28 insertions, 0 deletions
diff --git a/Test/D04parameter.ztst b/Test/D04parameter.ztst
index 6775803a7..57b87d687 100644
--- a/Test/D04parameter.ztst
+++ b/Test/D04parameter.ztst
@@ -333,6 +333,34 @@
0:${(Q)...} with handling of $'...'
>XABY
+ # The following may look a bit random.
+ # For the split we are checking that anything that
+ # would normally be followed by a different word has
+ # an argument break after it and anything that doesn't doesn't.
+ # For the (Q) we are simply checking that nothing disappears
+ # in the parsing.
+ foo='<five> {six} (seven) >eight< }nine{ |forty-two| $many$ )ten( more'
+ array=(${(z)foo})
+ print -l ${(Q)array}
+0:${(z)...} and ${(Q)...} for some hard to parse cases
+><
+>five
+>>
+>{six}
+>(
+>seven
+>)
+>>
+>eight
+><
+>}nine{
+>|
+>forty-two
+>|
+>$many$
+>)
+>ten( more
+
psvar=(dog)
setopt promptsubst
foo='It shouldn'\''t $(happen) to a %1v.'