summaryrefslogtreecommitdiffstats
path: root/lib.h
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2024-07-11 20:48:34 -0700
committerKaz Kylheku <kaz@kylheku.com>2024-07-11 20:48:34 -0700
commitb2bb2af765a550efd92adb25687cb76f955574e3 (patch)
treef1eaa8bf8750b3cba95a5d40f95e808d94fb60ca /lib.h
parentd9d8beefbf45eaea89d4174e55df37ed89690ec9 (diff)
downloadtxr-b2bb2af765a550efd92adb25687cb76f955574e3.tar.gz
txr-b2bb2af765a550efd92adb25687cb76f955574e3.tar.bz2
txr-b2bb2af765a550efd92adb25687cb76f955574e3.zip
New funtion related to where function.
* eval.c (eval_init): register intrinsics wheref, whereq, whereql and wherequal. * lib.c (wheref_fun): New static function. (wheref, whereq, whereql, wherequal): New functions. * lib.h (wheref, whereq, whereql, wherequal): Declared. * tests/012/seq.tl: New tests. * txr.1: Documented.
Diffstat (limited to 'lib.h')
-rw-r--r--lib.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib.h b/lib.h
index f83d59b0..5cb52990 100644
--- a/lib.h
+++ b/lib.h
@@ -1453,6 +1453,10 @@ val contains(val key, val seq, val testfun, val keyfun);
val rsearch(val seq, val key, val from, val to);
val search_all(val seq, val key, val testfun, val keyfun);
val where(val func, val seq);
+val wheref(val func);
+val whereq(val obj);
+val whereql(val obj);
+val wherequal(val obj);
val sel(val seq, val where);
val reject(val seq, val where);
val relate(val domain_seq, val range_seq, val dfl_val);