r/Forth • u/wengchunkn • Jan 26 '19
How Forth helps learning Haskell !!!
https://groups.google.com/forum/#!topic/comp.lang.forth/lpYwr5JtGbc
0
Upvotes
2
u/jephthai Jan 27 '19
A very enthusiastic post indeed, but most Forth programs are about as imperative as you get, with maximum side effects. I do think you can write Forth in a functional style, but it's not as idiomatic (or at least, as historically normal, anyway).
0
1
u/[deleted] Jan 27 '19
Having some experience from both languages, I can see where this is coming from.
Forth words compose similarly to Haskell functions, both allow leaving things unsaid and implicit that are explicit in most languages. But the control you have over the parameter stack in Haskell is much more formalized.
My own baby, Snigl (https://gitlab.com/sifoo/snigl); takes Forth several steps further in the general direction of Haskell.