3 ms·
In my mind, Forth "escapes" the whitespace-vs-delimiters issue by not having variadic functions. Forth code is more or less a direct transcription of the parse
by thaumasiotes 7y ago
In my mind, Forth "escapes" the whitespace-vs-delimiters issue by not having variadic functions. Forth code is more or less a direct transcription of the parse tree in the same way that lisp is, just postorder instead of preorder. And if you eliminated variadic functions from lisp, you wouldn't need its parentheses either.
- gmfawcett 7y agoI haven't Forthed in a long time, but you can write variadic words (e.g., "keep popping until a negative number is reached"). You just (a) shouldn't, probably; and (b) can't document their stack effect properly.