News for hackers. Stuff that matters.
Re:I learned Haskell in just 15 years by mrkeen on Monday June 17, 2024 @02:37PM (#40709357)
> I don't think you know what you're talking about.

Right. I sound just like someone talking about how "a language which emphasizes immutability" is an OK replacement for a language with pure functions.

Re:I learned Haskell in just 15 years by nequo on Monday June 17, 2024 @03:53PM (#40710247)
The world is much less black and white than you’d like to see it.

Functions in Haskell including Prelude can throw exceptions which is not reflected in the type signature of the function. That is an effect that makes seemingly pure functions impure.

You can’t judge a language from a list of buzzwords. You need to look at how it is used in practice.

Re:I learned Haskell in just 15 years by massysett on Monday June 17, 2024 @04:51PM (#40710905)
> Functions in Haskell including Prelude can throw exceptions which is not reflected in the type signature of the function. That is an effect that makes seemingly pure functions impure.

No, bottom, or _|_, is an inhabitant of every lifted type. An exception is bottom. So the / function is still pure even though it can throw a divide-by-zero exception.

Re:I learned Haskell in just 15 years by Nemerie on Tuesday June 18, 2024 @03:28PM (#40721250)
Does it make it type-safe though? In dynamic languages type errors also result in exceptions.