summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Shahaf <d.s@daniel.shahaf.name>2016-09-14 03:38:34 +0000
committerDaniel Shahaf <d.s@daniel.shahaf.name>2016-09-16 03:52:45 +0000
commita08f8a4c2925c421d9e74604fa720034c5440376 (patch)
tree24c5d4c922f3652e6fb7ae18298bc09f8861e43e
parent59aabe483c321f9122ea9998b0f0797eabe2aa6c (diff)
downloadzsh-a08f8a4c2925c421d9e74604fa720034c5440376.tar.gz
zsh-a08f8a4c2925c421d9e74604fa720034c5440376.zip
39310/0004: internals: match_str: Document 'savl'.
-rw-r--r--ChangeLog3
-rw-r--r--Src/Zle/compmatch.c17
2 files changed, 19 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index c3ed089ba..9fddd78d9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2016-09-16 Daniel Shahaf <d.s@daniel.shahaf.name>
+ * 39310/0004: Src/Zle/compmatch.c: internals: match_str: Document
+ 'savl'.
+
* 39310/0003: Src/Zle/compmatch.c: internals: match_str: Document
'savw'. Avoid magic number.
diff --git a/Src/Zle/compmatch.c b/Src/Zle/compmatch.c
index a3988d542..d32d9f1e1 100644
--- a/Src/Zle/compmatch.c
+++ b/Src/Zle/compmatch.c
@@ -641,7 +641,22 @@ match_str(char *l, char *w, Brinfo *bpp, int bc, int *rwlp,
* the temporal lobe. Reward promised for its safe return.
* Contact zsh-workers@zsh.org.
*/
- char *tp, savl = '\0';
+ char *tp;
+ /*
+ * Temporary variable. Used as temporary storage for a
+ *
+ * {
+ * () {
+ * local foo="$foo"
+ * foo[1]=bar
+ * ...
+ * }
+ * (use original $foo here)
+ * }
+ *
+ * operation. Similar to savw.
+ */
+ char savl;
/*
* The anchor on this end.
*/