about summary refs log tree commit diff
path: root/Test/E02xtrace.ztst
diff options
context:
space:
mode:
Diffstat (limited to 'Test/E02xtrace.ztst')
-rw-r--r--Test/E02xtrace.ztst25
1 files changed, 25 insertions, 0 deletions
diff --git a/Test/E02xtrace.ztst b/Test/E02xtrace.ztst
index 795f7e616..d72b2d000 100644
--- a/Test/E02xtrace.ztst
+++ b/Test/E02xtrace.ztst
@@ -180,3 +180,28 @@
 >	# traced
 >	echo inner
 >}
+
+ function -T { echo traced anonymous function }
+ functions -- -T # no output
+1:define traced function: anonymous function
+?+(anon):0> echo traced anonymous function
+>traced anonymous function
+
+ function -T f { echo traced named function }
+ functions -- -T # no output
+ functions f
+ f
+0:define traced function: named function
+>f () {
+>	# traced
+>	echo traced named function
+>}
+?+f:0> echo traced named function
+>traced named function
+
+ function -T -T { echo trace function literally named "-T" }
+ -T
+0:define traced function: parse test
+?+-T:0> echo trace function literally named -T
+>trace function literally named -T
+