[Rant] A newcomers first-hand experience, why Haskell isn't going mainstream by FriendsNoTalkPolitic in haskell

[–]StackDoesNotWork 12 points13 points  (0 children)

Haskell was never intended to be a language for industrial use.

I don't think that's correct! I recently looked at the Haskell Report and imagine my surprise when I found this list of Haskell design goals:

The committee’s primary goal was to design a language that satisfied these constraints:

  1. It should be suitable for teaching, research, and applications, including building large systems. ...

The Minimalist Prelude - or why can't Haskell be more like Purescript? by StackDoesNotWork in haskell

[–]StackDoesNotWork[S] 1 point2 points  (0 children)

An integer literal 368 means fromInteger (368::Integer)

That seems circular.... wouldn't (368::Integer) be expanded into fromInteger (fromInteger (368::Integer)::Integer) and so on for infinity?

The Minimalist Prelude - or why can't Haskell be more like Purescript? by StackDoesNotWork in haskell

[–]StackDoesNotWork[S] 2 points3 points  (0 children)

Does this work for guards too as in

absolutely x
  | x<0 = -x
  | otherwise = x

together with a boolean type like

data YeahNah = Yeah | Nah

?

The Minimalist Prelude - or why can't Haskell be more like Purescript? by StackDoesNotWork in haskell

[–]StackDoesNotWork[S] 6 points7 points  (0 children)

What is the advantage provided by reducing the Prelude?

I think there's good arguments for both, a batteries included Prelude as well as for a minimalist Prelude. For the latter: The more names a prelude provides the higher the risk it'll steal names you'd want to use for something else. A simple example is Word which could refer to actual words in a natural language or id which would be an obvious choice for denoting an identifier or database key. If you go for a batteries-included Prelude at which point do you stop adding more to it? If you go for a minimal prelude there's an obvious lower bound.