Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I like to code in Haskell because it's beautiful. I have tried coding Haskell in larger projects but that was a bad experience, they were a complicated mess of obscure Haskell extensions and methods with >20 types in their signature. So in my professional life I stick to the pragmatic ugliness of Scala or Java.


I wrote the backend for my side project http://cryptomarketdepth.com in Haskell (source: https://github.com/cryptomarketdepth/main) in Haskell.

I like to code in Haskell because it works better than any other language I’ve tried — also for larger projects. Where by “works better” I mean that I’m able to deduce what a piece of code does just by reading it more easily than for any other language I’ve tried.

I think it’s the combination of pure functions and strong types that enables this, but I’m not entirely sure.


As someone who dabbled in Scala in school and a professional Kotlin programmer, hearing someone recommend Scala as a sane alternative makes me fearful of Haskell.


It's not so much Haskell that is to blame, but how it's used in practice. To be fair, I have seen similar over-complicated projects in Scala and even in Java: but there it seems to be more rare.

The problem is, you have this language which offers you a million handy little tricks which seem very useful for all kinds of little niche problems. The boring and common sense approach would be not to use them, because it would give your colleagues too many headaches to figure out what they are and why you chose to use them. But in practice the temptation is often too strong.


> you have this language which offers you a million handy little tricks which seem very useful for all kinds of little niche problems.

The focus should be on the core abstractions like Functor, Monad, Monoid, Applicative, etc that are sound, non-leaky, universal abstractions that are useful for all kinds of little niche problems.

> The boring and common sense approach would be not to use them, because it would give your colleagues too many headaches to figure out what they are and why you chose to use them. But in practice the temptation is often too strong.

The boring Haskell approach you describe should include taking advantage of those core abstractions.

If your coworkers don't get them, they should learn the core abstractions and how to use them.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: