3 ms·
forth definitely has a language in it but i don't think the language is what led people to prefer it to, e.g., c or a nice macro assembler (i'd say 'leads' but
by kragen 4y ago
forth definitely has a language in it but i don't think the language is what led people to prefer it to, e.g., c or a nice macro assembler
(i'd say 'leads' but there don't seem to be a lot of people doing things in forth these days; duncan's 01988 estimate of 50000 'serious' forth programmers seems two orders of magnitude higher than seems likely today)
i think the appeal is that in 16k or 64k you get a repl which (unixlike) doubles as a scriptable ui, a sort of source-level debugging, interactive variable inspection (and i/o port poking, memory dumping, etc.), instant turnaround for changes (no 'my code's compiling'), multithreading, virtual memory, an assembler and disassembler, an extensible compiler with a turing-complete macro system, and dramatically better code density than machine code
all of that makes a pretty appealing package, especially for certain kinds of tasks, and it's only loosely coupled to the language qua language
as duncan points out, part of the appeal is that the development environment is a lot more integrated than something like turbo pascal