by TuringTest · 4y ago · 0 comments
That sounds a lot like "I don't see a need for functional languages because I'm already using them as libraries" ;-P
> Imo, local mutation is not that bad, and functional languages actively prevent it, while global mutation is still a thing, which tends to be more problematic
Many functional languages allow for local mutation as "cell" objects, if you want to abandon the purely functional paradigm for some encapsulated parts.
And you can do global mutation in a functional way, you just need to handle it with functional state-change idioms that maintain the referential transparency of the code (e.g. the State monad).
No comments yet.