summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--lib.c7
2 files changed, 6 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index c03eec78..11e76f2b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
2011-10-07 Kaz Kylheku <kaz@kylheku.com>
+ * lib.c (flatten_helper): Function removed.
+ (flatten): Recurse directly, using func_n1.
+
+2011-10-07 Kaz Kylheku <kaz@kylheku.com>
+
* txr.1: fxed wrong word.
2011-10-06 Kaz Kylheku <kaz@kylheku.com>
diff --git a/lib.c b/lib.c
index ed1e737a..02c08171 100644
--- a/lib.c
+++ b/lib.c
@@ -357,11 +357,6 @@ val ldiff(val list1, val list2)
return out;
}
-static val flatten_helper(val env, val item)
-{
- return flatten(item);
-}
-
val memq(val obj, val list)
{
while (list && car(list) != obj)
@@ -432,7 +427,7 @@ val flatten(val list)
if (atom(list))
return cons(list, nil);
- return mappend(func_f1(nil, flatten_helper), list);
+ return mappend(func_n1(flatten), list);
}
cnum c_num(val num);