diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2011-10-07 17:54:35 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2011-10-07 17:54:35 -0700 |
commit | f5af9dd56254dd90f5985eb3e1dcbab042d72431 (patch) | |
tree | 46ee763e18f46fe46b7c9ca8526ce4da0b49d14e | |
parent | e96daf6572cf4860d8d51d07fdabe6c9d69f959a (diff) | |
download | txr-f5af9dd56254dd90f5985eb3e1dcbab042d72431.tar.gz txr-f5af9dd56254dd90f5985eb3e1dcbab042d72431.tar.bz2 txr-f5af9dd56254dd90f5985eb3e1dcbab042d72431.zip |
* lib.c (flatten_helper): Function removed.
(flatten): Recurse directly, using func_n1.
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | lib.c | 7 |
2 files changed, 6 insertions, 6 deletions
@@ -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> @@ -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); |