3 ms·
Tail call elimination!!! I had no idea that this was in LISP 1.5. If you had asked me, I would have sworn it was Steele, 1977. Wikipedia supports that[1], albe
by nemoniac 4y ago
Tail call elimination!!!
I had no idea that this was in LISP 1.5. If you had asked me, I would have sworn it was Steele, 1977. Wikipedia supports that[1], albeit one might not consider it the most reliable source.
So apparently (partial) TCE has been around since at least 1961. In that light, it's baffling that it's not supported more universally.
[1] https://en.wikipedia.org/wiki/Tail_call https://en.wikipedia.org/wiki/Tail_call
- pflanze 4y agoThe OP describes the support in HLC for TCO as limited (only for self-recursion, if I get it right, possibly more limited than that). Steele may still have been first to describe general TCO.
- texdraft 4y agoYou could edit Wikipedia, citing Hart and Levin's memo introducing the compiler.
- aap_ 4y agoTail call optimization in scheme are automatic. This LISP 1.5 compiler simply recognizes certain patterns and rewrites them. Not quite the same thing but I was surprised as well when I first looked into the code.