Live data from Hacker News

Haskell is our first choice for building production software systems

foxhound.systems

41–50 of 297 posts

Re: Haskell is our first choice for building production software systems

#41

I dislike Haskell. But this article goes out of its way to make the worst possible case for Haskell imaginable. > Many programmers encounter statically typed languages like Java or C++ and find that the compiler feels like an annoyance. By contrast, Haskell’s static type system, in conjunction with compile-type time checking, acts as an invaluable pair-programming buddy that gives instantaneous feedback during develo…

[deleted]

Re: Haskell is our first choice for building production software systems

#42
post #14

Earlier quoted context omitted.

Actually, the reason why I found static typing annoying in the past (and why I felt more productive in Python) were the types are really low level (missing basic things like tuples) and lack of type inference. You have to repeat the type information, a lot. And also you have to declare lot of intermediate data structures. In Python, this became easier and one could focus on the data transformations, thinking about th…

I've joined several companies, and getting into a Python code base was the most difficult one, because of the lack of typed method parameters. It was easier with Java and better still with Scala - same for Typescript vs. Javascript. I would be interested, is your Python experience green field or joining a large project? (just wanting to know, not implying anything on your part).

I had the exact same experience: being a new employee at companies A and B, with large Python and Scala codebases respectively. At company B it was far easier to get on board and start writing code, and it has remained easy. Trying to make sense of Python was truly demoralizing, and a significant part of why I left company A.

Re: Haskell is our first choice for building production software systems

#43

I dislike Haskell. But this article goes out of its way to make the worst possible case for Haskell imaginable. > Many programmers encounter statically typed languages like Java or C++ and find that the compiler feels like an annoyance. By contrast, Haskell’s static type system, in conjunction with compile-type time checking, acts as an invaluable pair-programming buddy that gives instantaneous feedback during develo…

I guess you haven’t spend too much time with Haskell. Haskell types especially generic ones are way more expressive and limit your search quite a bit. The function Int -> Int -> Bool can not reach for a database or anything other than the two Ints it is given.

Re: Haskell is our first choice for building production software systems

#44
post #32

If you want to get a feel of the productivity using Haskell in production start with a simple CRUD app and use IHP ( https://ihp.digitallyinduced.com/ ) to build it. You will have something usable within a day - GUI and all. Then move further down the rabbit hole from there.

How about servant, and some popular js framework on top of that? IHP might be putting a lot of effort into the project, but the code generation part... I (personally) don't like that at all. And it's not common practice in haskell.

Re: Haskell is our first choice for building production software systems

#45
post #17

Earlier quoted context omitted.

> the reason they "find that the compiler feels like an annoyance" is because their first exposure to Java / C++ is in school where they have an assignment due for tonight and the compiler won't stop banging pages of errors about std::__1::basic_string > and what the fuck is that shit I just want to make games !!11!1! Well I can't imagine how much more annoyed they'd be when using an interpreted language which lets t…

I feel like it probably isn’t worthwhile to litigate the merits of static typing every time there is a HN post that’s vaguely adjacent to the topic. For the amount people care about it, there isn’t much evidence in either direction. And most studies that do exist are limited to small programs typically written by novices. Yale’s Singapore campus are going to be running two instances of the same course in parallel soo…

It would if python actually encouraged runtime coding.

In my opinion dynamic programmers need to embrace the runtime environment and use it as part of their development methodology. Unfortunately most popular dynamic languages have woeful runtime environments.

Re: Haskell is our first choice for building production software systems

#46
post #36
post #19

Earlier quoted context omitted.

> on the other hand you have an easier time to attract the few you need How is it easier to find a Haskell developer vs finding a Java/Python/PHP developer?

I've never hired a Haskell developer, but anecdotally from my friends and associates who have, if you put out an advertisement for a Java/Python/PHP developer you get 500 applications from average candidates. If you put out an advertisement for a Haskell developer you get 5 applications from good candidates.

You probably got 500 applications for Java/Python/PHP, of those 450 average and let's say 50 good.

With Haskell you just get 5 good ones. You probably don't start with Haskell as your first language but rather move into it after you are a senior in another language. If you are lousy in Java, you probably won't go and learn Haskell or some other niche language.

Re: Haskell is our first choice for building production software systems

#47

I dislike Haskell. But this article goes out of its way to make the worst possible case for Haskell imaginable. > Many programmers encounter statically typed languages like Java or C++ and find that the compiler feels like an annoyance. By contrast, Haskell’s static type system, in conjunction with compile-type time checking, acts as an invaluable pair-programming buddy that gives instantaneous feedback during develo…

I guess you haven’t spend too much time with Haskell. Haskell types especially generic ones are way more expressive and limit your search quite a bit. The function Int -> Int -> Bool can not reach for a database or anything other than the two Ints it is given.

I guess I read the article and commented on what the article was saying and claiming. Hence the introductory sentences at the top of my post.

Re: Haskell is our first choice for building production software systems

#48

I dislike Haskell. But this article goes out of its way to make the worst possible case for Haskell imaginable. > Many programmers encounter statically typed languages like Java or C++ and find that the compiler feels like an annoyance. By contrast, Haskell’s static type system, in conjunction with compile-type time checking, acts as an invaluable pair-programming buddy that gives instantaneous feedback during develo…

To clarify the sibling, a signature of `Int -> Int -> Bool` can't do any IO (so no connecting to databases, reading/writing files, network requests), so it does tell you a lot about a function.

It can manipulate strings, decode JSON, but both of these are either (immutable) values from enclosing scope, or created within the function. But since they can't be output anywhere (because no IO) then they don't matter.

EDIT:

I'll just add a few more counterpoints.

Agreed that DSLs are difficult, and often not worth the trouble. But if you do want to create a DSL, then haskell is a good fit because of monads and monad transformer stacks - i.e you can make the statement mean whatever you want it to mean, and keep the effects in check with types.

The synergy between higher order functions with typed IO is great, better than in other languages.

Agreed that IDE refactoring is convenient, and also refactoring in other languages with static type checking the process is similar to what they describe in the article, so no immediate "pro" there.

Re: Haskell is our first choice for building production software systems

#49
I think most programmers nowadays face no interesting problems to solve. They crave for a mental challenge, but instead of looking for a job that requires solving hard engineering problems, they believe they can satisfy their mental needs with coding in “somewhat” hard language.

Re: Haskell is our first choice for building production software systems

#50

Good luck scaling this to organization of 100+ engineers. You will soon learn the tradeoff between writing and reading code. And the stark realities of the dev hiring markets and the thing called a learning curve.

Is is actually hard to hire for Haskell? You can’t just tell some random to learn it (because his head will explode), but my impression is that you’ll have candidates coming out of the woodwork who could never get away with using it before but always wanted to .

Quite a few universities in the UK teach haskell as a way to start everyone on a level playing field and to introduce various concepts.
Post reply on HN