about summary refs log tree commit diff
path: root/Test
diff options
context:
space:
mode:
authorPeter Stephenson <p.w.stephenson@ntlworld.com>2015-07-04 11:01:47 +0100
committerPeter Stephenson <p.w.stephenson@ntlworld.com>2015-07-04 11:01:47 +0100
commitf2b2271fbe4a7acb1b026545481bf5cd6879d983 (patch)
treeb8bb0211b7cfd2c0ecd43706602ee1c6c77c1e1a /Test
parenta257525afc1578ff4d951e6771b2afab181ac46e (diff)
downloadzsh-f2b2271fbe4a7acb1b026545481bf5cd6879d983.tar.gz
zsh-f2b2271fbe4a7acb1b026545481bf5cd6879d983.tar.xz
zsh-f2b2271fbe4a7acb1b026545481bf5cd6879d983.zip
Turning case parsed as multiple alternatives back into text.
Also add test.
Diffstat (limited to 'Test')
-rw-r--r--Test/A01grammar.ztst24
1 files changed, 24 insertions, 0 deletions
diff --git a/Test/A01grammar.ztst b/Test/A01grammar.ztst
index 50058e25d..8221735b6 100644
--- a/Test/A01grammar.ztst
+++ b/Test/A01grammar.ztst
@@ -695,3 +695,27 @@
 0:Balanced parentheses and spaces with zsh pattern
 >It worked
 >That worked, too
+
+  fn() {
+    typeset ac_file="the else branch"
+    case $ac_file in
+      *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
+      *.* ) break;;
+      *)
+      ;;
+    esac
+    print Stuff here
+  }
+  which fn
+  fn
+0:Long case with parsed alternatives turned back into text
+>fn () {
+>	typeset ac_file="the else branch" 
+>	case $ac_file in
+>		(*.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj)  ;;
+>		(*.*) break ;;
+>		(*)  ;;
+>	esac
+>	print Stuff here
+>}
+>Stuff here