3 ms·
I've built the beginnings of a Forth compiler in Common Lisp just to prove the concept. I find Forth syntax more convenient for some tasks (like emitting a seri
by dreamcompiler 5y ago
I've built the beginnings of a Forth compiler in Common Lisp just to prove the concept. I find Forth syntax more convenient for some tasks (like emitting a series of HTML constructs to a stream, in precise order) than Lisp syntax and since Common Lisp gives you access to the values stack it's pretty easy to turn it into Forth. Of course you have to give up variadic functions, but that's the nature of Forth.
I haven't tried the reverse (building a Lisp in Forth) but I imagine it would be straightforward. One can build a Lisp from just about anything.