DEV Community

Discussion on: Switching to Haskell

Collapse
 
deciduously profile image
Ben Lovy

Not necessarily, it's a fact of life in most domains, but it does provide a rich toolkit for organizing and sequestering the mutable and effectful parts of your code.

Collapse
 
gabrielfallen profile image
Alexander Chichigin

Not necessarily, it's a fact of life in most domains

If you're referring to mutable state, then it's irrelevant whether it's a fact of life or not. Because in software development we're modelling real-life domains. And we can easily model mutable state with immutable data structures and pure functions. Surprisingly often it leads to both fever errors and simpler code.

Thread Thread
 
wrldwzrd89 profile image
Eric Ahnell

This is exactly why side effect-free coding by default is so valuable: it’s far easier to verify correct behavior.

Collapse
 
trishaganesh09 profile image
Trisha

True, but the good thing is that it requires a lot of focus as it is a hard language for most people.