4 ms·
The biggest reasons for this are local variables vs. stack ops and parenthesized expressions vs. having to know the arities of the words called. You can add loc
by abecedarius 9y ago
The biggest reasons for this are local variables vs. stack ops and parenthesized expressions vs. having to know the arities of the words called. You can add local variables to Forth, but afaik nobody did during its heyday; and "phrasing" your code with whitespace can help some on the latter issue, but it's admittedly not as explicit as parens.
(From another one-time Forther and more recent Lisper.)
- dreamcompiler 9y agoMach 2 Forth for the Mac in the late 80s had local variables and when I wrote a Forth compiler for the TI 34010 I included local variables. They helped a lot, but they still don't make Forth as readable as Lisp.