Re:Ask HN: Why is functional programming not more popular?
by valand on Wednesday November 06, 2019 @01:53PM
(#21465707)
I didn't mean to say immutabilty and no-side-effects are advertised less. It's just not enough of them are effective.
Those concepts helped me avoid a lot of headaches without knowing that those are concepts of FP. Then there was a day where I just realized, "Oh, this is FP"
I guess people need to be educated, or experience themselves, the concepts, before hearing the word "FP" which mean less to them.
The examples provided in the internet needs to be more ambituous than mere chains of functions. They need to be "remaking rsync with minimum IFs" or "large scale React App without a single getDerivedState"
Also, can't resist nitpicking about tail call optimization: clang/llvm and gcc implement it in a non-gc language (C), but meanwhile some FP language implementations lack it, at least Clojure does. So while there's more demand for that feature in the FP world and some FP languages like Scheme require implementations to perform this optimization, it's conceptually somewhat orthogonal to FP or GC.