by capableweb · 3y ago · 0 comments
Functionality moves (c) => (b) => (a).
Unless it's a DSL, the osmotic power is strong.
(remove-if-not #'oddp #(1 2 3 4 5))
you have to write a loop from scratch, and then everyone has to read it carefully to learn what it’s doing (and especially what it’s not).Don’t get too excited about having HTTP or JSON built in, we weren’t using those in 1990 and they’ll surely be replaced by 2050.
That probably wouldn't be the case if it had been named retain-if or keep-if; the issue is likely the double negative.
A function which pares down a sequence to just those elements which match a predicate is very useful; why would you deprecate such a thing.
These days the function is usually called filter, but I'm not sure it was a commonly used term then.
That would be terrible, those loops are crazy dangerous. I would avoid writing a loop and rather come up with a whole different programming paradigm. Maybe a macro system or something based on category theory?
You just really don’t need much to get stuff done with a lisp.