diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2014-11-20 19:59:50 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2014-11-20 19:59:50 -0800 |
commit | d4b9a1e45899f86dbb9d5bef1f53fffa9dc05d44 (patch) | |
tree | 72d8ed7b5ee105ce47332e46c11a4f1a799e8b55 /eval.c | |
parent | 87626d48be8c54b4aa53cb4829ff1c3fc34eb02e (diff) | |
download | txr-d4b9a1e45899f86dbb9d5bef1f53fffa9dc05d44.tar.gz txr-d4b9a1e45899f86dbb9d5bef1f53fffa9dc05d44.tar.bz2 txr-d4b9a1e45899f86dbb9d5bef1f53fffa9dc05d44.zip |
* arith.c (succ, ssucc, sssucc, pred, ppred, pppred): New functions.
* eval.c (eval_init): Register new functions as intrinsics.
* lib.h (succ, ssucc, sssucc, pred, ppred, pppred): Declared.
* txr.1: Documented.
Diffstat (limited to 'eval.c')
-rw-r--r-- | eval.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -3709,6 +3709,12 @@ void eval_init(void) reg_fun(intern(lit("zerop"), user_package), func_n1(zerop)); reg_fun(intern(lit("evenp"), user_package), func_n1(evenp)); reg_fun(intern(lit("oddp"), user_package), func_n1(oddp)); + reg_fun(intern(lit("succ"), user_package), func_n1(succ)); + reg_fun(intern(lit("ssucc"), user_package), func_n1(ssucc)); + reg_fun(intern(lit("sssucc"), user_package), func_n1(sssucc)); + reg_fun(intern(lit("pred"), user_package), func_n1(pred)); + reg_fun(intern(lit("ppred"), user_package), func_n1(ppred)); + reg_fun(intern(lit("pppred"), user_package), func_n1(pppred)); reg_fun(intern(lit(">"), user_package), func_n1v(gtv)); reg_fun(intern(lit("<"), user_package), func_n1v(ltv)); reg_fun(intern(lit(">="), user_package), func_n1v(gev)); |