summaryrefslogtreecommitdiffstats
path: root/eval.c
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2022-05-28 22:40:59 -0700
committerKaz Kylheku <kaz@kylheku.com>2022-05-28 22:40:59 -0700
commitbc591cb5ee04582dbdf17a0125987ec03e8c064f (patch)
treed105da9c40623bf044a4d03ff1c8b270a1c8a466 /eval.c
parent3692b3b96af9159368a7bfe63798bb67ff90367f (diff)
downloadtxr-bc591cb5ee04582dbdf17a0125987ec03e8c064f.tar.gz
txr-bc591cb5ee04582dbdf17a0125987ec03e8c064f.tar.bz2
txr-bc591cb5ee04582dbdf17a0125987ec03e8c064f.zip
tok-str: takes count argument.
* eval.c (eval_init): Update registration of tok-str. * lib.c (tok_str): New argument, count_opt. Implemented in the compat 155 case; what the heck. (tok): Pass nil to new parameter of tok_str. * lib.h (tok_str): Declaration updated. * tests/015/split.tl: New tests. * txr.1: Documented.
Diffstat (limited to 'eval.c')
-rw-r--r--eval.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/eval.c b/eval.c
index 2b95dae4..cbe37f55 100644
--- a/eval.c
+++ b/eval.c
@@ -7217,7 +7217,7 @@ void eval_init(void)
reg_fun(intern(lit("spl"), user_package), func_n3o(spl, 2));
reg_fun(intern(lit("split-str-set"), user_package), func_n2(split_str_set));
reg_fun(intern(lit("sspl"), user_package), func_n2(sspl));
- reg_fun(intern(lit("tok-str"), user_package), func_n3o(tok_str, 2));
+ reg_fun(intern(lit("tok-str"), user_package), func_n4o(tok_str, 2));
reg_fun(intern(lit("tok"), user_package), func_n3o(tok, 2));
reg_fun(intern(lit("tok-where"), user_package), func_n2(tok_where));
reg_fun(intern(lit("list-str"), user_package), func_n1(list_str));