diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2011-11-17 11:18:42 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2011-11-17 11:18:42 -0800 |
commit | 68ca87bc780e25dea1418019161d99727225d1ce (patch) | |
tree | 7e4651a1e61db5c2205c518257e9c5bd9355037a /txr.1 | |
parent | 2668e984caf88abb2bd8d20d50573f23e73aa695 (diff) | |
download | txr-68ca87bc780e25dea1418019161d99727225d1ce.tar.gz txr-68ca87bc780e25dea1418019161d99727225d1ce.tar.bz2 txr-68ca87bc780e25dea1418019161d99727225d1ce.zip |
* match.c (h_fun, v_fun): Bugfix! copy_list should be used for copying
the bindings, not copy_alist. Otherwise functions cannot destructively
update a binding, which is useless. We want a function not to
manipulate the binding list, but to be able to manipulate the
contents of bindings.
(match_files_ctx): Declaration moved ahead of match_line.
(v_fun): Forward declaration added.
(match_line): Allow vertical functions to be called from
a horizontal context, in a limited way.
* txr.1: Mention the possibility of a call from a horizontal
context falling back on a vertical function.
Diffstat (limited to 'txr.1')
-rw-r--r-- | txr.1 | 9 |
1 files changed, 7 insertions, 2 deletions
@@ -3021,8 +3021,13 @@ Example: Output: fun="horizontal" -A call made in a clearly horizontal context will ignore -the vertical definition, if any, and require the horizontal function. +A call made in a clearly horizontal context will prefer the +horizontal function, and only fall back on the vertical one +if the horizontal one doesn't exist. (In this fall-back case, +the vertical function is called with empty data; it is useful +for calling vertical functions which process arguments and +produce values.) + In the next example, the call is followed by trailing material, placing it in a horizontal context. Leading material will do the same thing: |