summaryrefslogtreecommitdiffstats
path: root/txr.1
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2014-11-20 19:08:22 -0800
committerKaz Kylheku <kaz@kylheku.com>2014-11-20 19:08:22 -0800
commite680fcaaa59d181af0356d7446ca1e5628598215 (patch)
tree1bae4a1e7631719fe405728a21c2ea9400eae04b /txr.1
parentdececfe937e68c45c3658cf9fa30bcde362d30ff (diff)
downloadtxr-e680fcaaa59d181af0356d7446ca1e5628598215.tar.gz
txr-e680fcaaa59d181af0356d7446ca1e5628598215.tar.bz2
txr-e680fcaaa59d181af0356d7446ca1e5628598215.zip
* lib.c (sel): Accept a function in place of the index list.
* txr.1: Documented.
Diffstat (limited to 'txr.1')
-rw-r--r--txr.115
1 files changed, 14 insertions, 1 deletions
diff --git a/txr.1 b/txr.1
index 74e542f4..7b4d85fe 100644
--- a/txr.1
+++ b/txr.1
@@ -13312,7 +13312,7 @@ that element is added to a list. Finally, the list is returned.
.coNP Function @ select
.synb
-.mets (select < object << index-list )
+.mets (select < object >> { index-list <> | function })
.syne
.desc
@@ -13327,6 +13327,19 @@ the indices in
.metn index-list .
If
+.meta function
+is given instead of
+.metn index-list ,
+then
+.meta function
+is invoked with
+.meta object
+as its argument. The return value is then taken as
+if it were the
+.meta index-list
+argument .
+
+If
.meta object
is a sequence, then
.meta index-list