about summary refs log tree commit diff
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
parentdb717e3025b54d363d0f25908485370b10c9ec6a (diff)
downloadzsh-25413054c11fc4b67284d4d6db48272182da1d26.tar.gz
zsh-25413054c11fc4b67284d4d6db48272182da1d26.tar.xz
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.'