diff options
author | Daniel Shahaf <d.s@daniel.shahaf.name> | 2020-03-19 18:11:39 +0000 |
---|---|---|
committer | Daniel Shahaf <d.s@daniel.shahaf.name> | 2020-03-22 02:23:53 +0000 |
commit | aed0cb4408bffe2da89a25054b22144f616bdffe (patch) | |
tree | c9910a0e1ecc87187f3264b31189b098037178d0 /Test | |
parent | 386d9ac8ff961b8f0333d09511e927ab31011658 (diff) | |
download | zsh-aed0cb4408bffe2da89a25054b22144f616bdffe.tar.gz zsh-aed0cb4408bffe2da89a25054b22144f616bdffe.tar.xz zsh-aed0cb4408bffe2da89a25054b22144f616bdffe.zip |
45583/0009: Add end-of-options guard support to 'function -T'.
Diffstat (limited to 'Test')
-rw-r--r-- | Test/E02xtrace.ztst | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/Test/E02xtrace.ztst b/Test/E02xtrace.ztst index d72b2d000..8b9cc89a8 100644 --- a/Test/E02xtrace.ztst +++ b/Test/E02xtrace.ztst @@ -199,9 +199,29 @@ ?+f:0> echo traced named function >traced named function - function -T -T { echo trace function literally named "-T" } + function -T -- -T { echo trace function literally named "-T" } -T + function -T -- { echo trace anonymous function } + functions -- -- # no output 0:define traced function: parse test ?+-T:0> echo trace function literally named -T >trace function literally named -T +?+(anon):0> echo trace anonymous function +>trace anonymous function + + function -- g { echo g } + g + function -- { echo anonymous } + functions -- -- # no output +0:function end-of-"options" syntax, #1 +>g +>anonymous + + function -- -T { echo runs } + functions -- -- # no output + echo the definition didn\'t execute it + -T +0:function end-of-"options" syntax, #2 +>the definition didn't execute it +>runs |