From 0cffb0a6b3602a00cebe2bbb7537d76727892959 Mon Sep 17 00:00:00 2001 From: Daniel Shahaf Date: Thu, 18 Jun 2020 11:42:19 +0000 Subject: 46072 + 46136: Add the 'zle $widget -f nolast' syntax, to improve add-zle-hook-widget support for multiple hook functions. See workers/46004 for the use-case. --- Test/X04zlehighlight.ztst | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'Test') diff --git a/Test/X04zlehighlight.ztst b/Test/X04zlehighlight.ztst index 7ab050bee..ea1d64fe1 100644 --- a/Test/X04zlehighlight.ztst +++ b/Test/X04zlehighlight.ztst @@ -198,6 +198,17 @@ 0:overlapping region_highlight with near-color (hex-triplets at input) >0m27m24mCDE|340|tCDE|3160|rCDE|39|CDE|340|ueCDE|39| + zpty_start + zpty_input 'f () { zle clear-screen; zle g -f nolast; BUFFER=": ${(q)LASTWIDGET}" }; zle -N f' + zpty_input 'g () { }; zle -N g' + zpty_input 'bindkey "\C-a" f' + zpty_enable_zle + zpty_input $'\C-a' + zpty_line 1 p + zpty_stop +0:zle $widgetname -f nolast +>0m27m24m0m27m24m: clear-screen + %clean zmodload -ui zsh/zpty -- cgit 1.4.1