There are a couple of sides to the issue
- The technical definition of “pure”. That’s what Richard, gilmi and I have been discussing.
- Regardless of the technical definition, the impression it gives to the outside world. I think this is the main thrust of your original post, William.
I agree with you, William. In so many online discussions in general programming fora I see comments of the following sort:
Haskell is a pure language, that means it can’t have state or side effects, but modifying state and causing side effects are essential in a real-world system, therefore Haskell is useless in the real world.
My mind always boggled how such commenters could believe what they are saying. Do massive corporations like Facebook and Standard Chartered really use Haskell despite it being useless in the real world?! But the point remains: people do seem to think this.
I’m with gilmi and (I think, you): not only does “pure” (in the programming language sense, let alone the moral sense) give the wrong connotations, it’s not even what we value at all! We value referential transparency. The notion of “purity” is a poorly-defined approximation to referential transparency.
Here’s a challenge to folks who like the notion that “Haskell is a pure language”: please explain what benefit you get from Haskell’s “purity” that is not also a benefit of Haskell’s referential transparency.