summaryrefslogtreecommitdiffstats
path: root/lib.h
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2011-11-19 12:05:39 -0800
committerKaz Kylheku <kaz@kylheku.com>2011-11-19 12:05:39 -0800
commit1f3d894dab47e0d2527adf7db0b74296f19f7b81 (patch)
treec1f427b2c9d03760e1563ae53302359b7dc3cdb4 /lib.h
parentd3ba0368d9c5012ca9405ac55a6d9a632fb0895a (diff)
downloadtxr-1f3d894dab47e0d2527adf7db0b74296f19f7b81.tar.gz
txr-1f3d894dab47e0d2527adf7db0b74296f19f7b81.tar.bz2
txr-1f3d894dab47e0d2527adf7db0b74296f19f7b81.zip
deffilter grows in power: it can take quasistrings.
* lib.c (cdr_f): New global variable. (funcall1, funcall2, funcall3, funcall4): Fix unterminated arguments in uw_throwf call by using uw_throw instead. (do_or): New static function. (orf): New function. (obj_init): gc_protect and initialize cdr_f. * lib.h (cdr_f, orf): Declared. * match.c (v_deffilter): Treat the table as forms to be evaluated which must reduce to strings, rather than literal strings. * txr.1: Documented.
Diffstat (limited to 'lib.h')
-rw-r--r--lib.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib.h b/lib.h
index 5700a35c..4ad5e7a0 100644
--- a/lib.h
+++ b/lib.h
@@ -261,7 +261,7 @@ extern val nothrow_k, args_k;
extern val null_string;
extern val null_list; /* (nil) */
-extern val identity_f, equal_f, eq_f, car_f;
+extern val identity_f, equal_f, eq_f, car_f, cdr_f;
extern const wchar_t *progname;
extern val prog_string;
@@ -399,6 +399,7 @@ val curry_123_23(val fun3, val arg1);
val curry_1234_34(val fun3, val arg1, val arg2);
val chain(val first_fun, ...);
val andf(val first_fun, ...);
+val orf(val first_fun, ...);
val swap_12_21(val fun);
val vector(val alloc);
val vec_get_fill(val vec);