rpg juxtaposed lisp to C++ on Stroustrup’s terms. Stroustrup gives the beauty of C++ as being its opportunities for efficiency. rpg offers that lisp’s beauty instead comes from its Alexandrian habitability. Habitability being how easy a program is to live with and in while it exists. This reflects lisp’s fundamental acknowledgements that authoring original computer programs is always the hardest thing, and lisp’s precedent has been to make basically any available sacrifice to make authoring new programs easier. I would argue this includes a natural tendency to sacrifice business profitability in exchange for better programs - a balancing act that makes businesspeople rightfully nervous.
The pervasive lisp habitability example is garbage collection. Lisp tracks your consing for you, instead of having you do something like malloc(3) and free(3). This sacrifices Stroustrup’s beautiful possibility of efficiency in order for lisp programmers to focus what powers they have on programming instead of accounting. Lisp sacrificed possibilities of efficiency for habitability. The meme language rust defines garbage collection being obviously useful as a compile time error. Rust sacrifices habitability for… ennui? Habitability is the better choice.
Habitability is not the same as simple-mindedness. The least thoughtful approach to a home is not the most habitable home. Architecture matters. Garbage collection turned out over the decades to be quite nuanced.
Here is a trick used on game programmers: If you keep consing in a gameplay loop that affects your framerate, the garbage collection correctly doing useful work will happen inside your framerate affecting gameplay loop. So, the trickster continues, you should use a language where you have no choice but to allocate all your memory manually.
This is an interesting point in that lisp’s garbage collection did not mean never thinking about anything. Habitability is not the same as simple-mindedness. On the other hand, sacrificing your programming resources in order to bean count memory allocations everywhere including your gameplay loop still takes your time and effort, making your programming worse. Pushing all your bean counting to the very front of your programming where you have the least learned context and equipment to deal with it (making bean counting into compile time errors) is a special form of making your programming worse.
Another case of pushing bean counting to the front of the program is mandatory typing. ANSI common lisp’s approach is slightly subtle. Types are optional declarations. A type being declared incorrectly, where the incorrectly declared type does not cause an error is a WARNing in lisp, not an error. This is not either of the simple minded approaches of never declaring types or always requiring upfront-correct-waterfall-static-types.
See you on the mastodon! Talk here.. I think sharing on the Mastodon really helps. Boisterous conversation helps more.
I lisp a lot every day.