summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2014-03-12 22:03:58 -0700
committerKaz Kylheku <kaz@kylheku.com>2014-03-12 22:03:58 -0700
commit03e6fc5649ab4548fc331a0fe8bb5ed93eb296db (patch)
tree5da279b8fed550416afefe04f89bdd6e3aeff952
parent5bf88f48fe8233955b3346ccea14f8e3fae38286 (diff)
downloadtxr-03e6fc5649ab4548fc331a0fe8bb5ed93eb296db.tar.gz
txr-03e6fc5649ab4548fc331a0fe8bb5ed93eb296db.tar.bz2
txr-03e6fc5649ab4548fc331a0fe8bb5ed93eb296db.zip
* lib.c (iffi): Bugfix: was still using incorrect, outdated optional
argument defaulting logic.
-rw-r--r--ChangeLog5
-rw-r--r--lib.c3
2 files changed, 6 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index dac12d72..e8ddb285 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
2014-03-12 Kaz Kylheku <kaz@kylheku.com>
+ * lib.c (iffi): Bugfix: was still using incorrect, outdated optional
+ argument defaulting logic.
+
+2014-03-12 Kaz Kylheku <kaz@kylheku.com>
+
* eval.c (plus_s, prof_s): New symbol global variables.
(op_prof, me_pprof): New static functions.
(eval_init): Intern prof symbol, store in prof_s.
diff --git a/lib.c b/lib.c
index e7fa9ff9..885455ed 100644
--- a/lib.c
+++ b/lib.c
@@ -3871,8 +3871,7 @@ val iff(val condfun, val thenfun, val elsefun)
val iffi(val condfun, val thenfun, val elsefun)
{
- if (!elsefun)
- elsefun = identity_f;
+ elsefun = default_arg(elsefun, identity_f);
return func_f0v(cons(condfun, cons(thenfun, elsefun)), do_iff);
}