about summary refs log tree commit diff
path: root/Src/Zle/zle.h
diff options
context:
space:
mode:
authorPeter Stephenson <pws@zsh.org>2017-06-01 17:56:14 +0100
committerPeter Stephenson <pws@zsh.org>2017-06-01 17:56:14 +0100
commita6135f6114697c7755590b26062668d18f267d2b (patch)
treeb2a1885fffc458e50ed6eaad4b9995bdd5c1b2de /Src/Zle/zle.h
parent01fb5690095b91fa760df6d451aa0e58c51bee66 (diff)
downloadzsh-a6135f6114697c7755590b26062668d18f267d2b.tar.gz
zsh-a6135f6114697c7755590b26062668d18f267d2b.tar.xz
zsh-a6135f6114697c7755590b26062668d18f267d2b.zip
41191: Check for immortal thingies when checking for specific thingies
Diffstat (limited to 'Src/Zle/zle.h')
-rw-r--r--Src/Zle/zle.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/Src/Zle/zle.h b/Src/Zle/zle.h
index 8f92e5611..07b310180 100644
--- a/Src/Zle/zle.h
+++ b/Src/Zle/zle.h
@@ -230,6 +230,13 @@ struct thingy {
 /* DISABLED is (1<<0) */
 #define TH_IMMORTAL	(1<<1)    /* can't refer to a different widget */
 
+/*
+ * Check if bindk refers to named thingy (a set of bare characters),
+ * also checking the special .thingy widget.
+ */
+#define IS_THINGY(bindk, name)				\
+    ((bindk) == t_ ## name || (bindk) == t_D ## name)
+
 /* command modifier prefixes */
 
 struct modifier {