It's a pure functional language. You can do functional programming in many languages, but Haskell enforces it by design. From what I've seen of the type system, it's quite nice as well. Functional programming allows a great deal of confidence in your code,
Ask HN: Why would anyone choose Haskell to develop applications?
31–40 of 128 posts
Re: Ask HN: Why would anyone choose Haskell to develop applications?
#32Earlier quoted context omitted.
> I think the Python/JS/Go crew Genuine question: are these people a crew? I doubt very much each individual constituency in that trio would think so. JS and Go are really very different things with different mindsets. Python vs JS likewise.
No, it just means the people that tend to be attracted to these types of languages. Easy to get started languages that hide much of the inner workings from you as a dev.
I concede (having a fair amount of past experience of functional programming languages, including Orwell, which influenced Haskell) that choosing a functional programming language for development helps you pre-select people who are well-educated in CS concepts. But I am far from convinced that it's an approach that is particularly likely to lead to a crack team of business-focussed developers. It's just as likely to lead to a herd of cats.
Re: Ask HN: Why would anyone choose Haskell to develop applications?
#33Earlier quoted context omitted.
You will get slightly better people but still the wrong people. JS is almost never the right tool for the job, Go is occasionally the right tool for the job, mainly if you need to write something that moves bytes from one fd to another without much in the way of business logic. TBH if you are building something boring you should just use Spring w/Java or Kotlin. This will attract pragmatists that ship code that works…
Go doesn’t attract mediocrity it attracts pragmatism. I worked on a Scala team for a couple years, had a lot of devs that were “smart”, problem was they wrote really fancy code no one could understand. I then switched to a Go team and it was night and day. I was wildly more productive and the people in the community were not lacking intelligence. Go prioritizes community, it believes that “us” is more impactful than…
Go is big enough that this certainly doesn't hold for tens of thousands of developers.
Re: Ask HN: Why would anyone choose Haskell to develop applications?
#34Earlier quoted context omitted.
This can cut both ways. Yes, if you choose Haskell, a Lisp, or something like Erlang, you can get smarter/better devs. But the flip side of that is that the types of people who tend to gravitate toward those languages are often more interested in programming for it's own sake and not the domain they're working in. So you get things like people burning hours writing their own libraries and endless tinkering with progr…
This is where I differ. I think the Python/JS/Go crew gets you stuff that is built poorly and becomes expensive to maintain. I much prefer the JVM and ASP.NET crew because they are 9-5 programmers, their tools aren't constantly changing so for the most part they only need to spend time actually doing work. No fighting with package managers, no updating the latest framework and solving backwards incompatibilities for…
I too want my programmers to be thinking about and solving my business problems, not writing boilerplate.
Re: Ask HN: Why would anyone choose Haskell to develop applications?
#35Earlier quoted context omitted.
Maybe the same applies to building a RESTful API and choosing Go instead of js :)
You will get slightly better people but still the wrong people. JS is almost never the right tool for the job, Go is occasionally the right tool for the job, mainly if you need to write something that moves bytes from one fd to another without much in the way of business logic. TBH if you are building something boring you should just use Spring w/Java or Kotlin. This will attract pragmatists that ship code that works…
edit: ps: Big fan of OCaml, but have since moved on to Go and Python for getting things done in the real world.
Re: Ask HN: Why would anyone choose Haskell to develop applications?
#36When I asked my current employer why they chose it, they simply responded that it attracts the "right" people. From a business perspective, any language is arbitrary. What matters is having clever people around to solve problems.
Jane Street has the same rationale.
Re: Ask HN: Why would anyone choose Haskell to develop applications?
#37Re: Ask HN: Why would anyone choose Haskell to develop applications?
#38Earlier quoted context omitted.
This is where I differ. I think the Python/JS/Go crew gets you stuff that is built poorly and becomes expensive to maintain. I much prefer the JVM and ASP.NET crew because they are 9-5 programmers, their tools aren't constantly changing so for the most part they only need to spend time actually doing work. No fighting with package managers, no updating the latest framework and solving backwards incompatibilities for…
I prefer Javascript/Go/Python because most of my code is actually doing something instead of just conforming to a Gang Of Four pattern designed to paper over the shortcomings of my tool. I too want my programmers to be thinking about and solving my business problems, not writing boilerplate.
Re: Ask HN: Why would anyone choose Haskell to develop applications?
#39Earlier quoted context omitted.
You will get slightly better people but still the wrong people. JS is almost never the right tool for the job, Go is occasionally the right tool for the job, mainly if you need to write something that moves bytes from one fd to another without much in the way of business logic. TBH if you are building something boring you should just use Spring w/Java or Kotlin. This will attract pragmatists that ship code that works…
> If you are prototyping extremely quickly then maybe Ruby on Rails might be the right tool for the job (and thus attract the right kind of people). I am puzzled by this because my early experience of Ruby On Rails (and I mean early -- 2005) is that every Rails developer I encountered knew much less than they were letting on. > Go attracts mediocrity and not in a good way, it also actively repels the "right " people…
I even wrote some pretty good code in it.
However a few things became very clear to me over time.
1. Go is -not- a general purpose language. It lacks expressiveness necessary for this purpose which leads to overly hard to follow and refactor business logic, repetitive and error-prone (hah) error handling. Poor/inconsistent null handling. Highly variable quality standard library (some stuff is amazing like it's HTTP and TLS stacks). This leads it to be very good at one thing and one thing only, network servers, preferably operating at the protocol level. I think if you want to write a custom DNS, TFTP, or other simple network protocol and you cbf using Rust then Go is a great choice.
2. Go is easily picked up but very hard to master and the reward for mastery is much lower than languages that have similar learning curves. I would say I got very close to mastery but gave up short of the goal. Some things that come to mind here are handling of channels especially in select statements is much more nuanced than most would imagine, hell channels in general are -very- subtle. Subtle is never a word I want to hear when talking about a tech that I'm expected to support and mentor juniors to use.
3. Go leads to masses of very poor quality code that becomes extremely expensive to refactor, in large part due to language design decisions. However it's also a follow on effect of the above point but that applies equally to Python, JS, Ruby etc. What makes Go unique in this regard is that it is already a very verbose language but goes further to have a poor module system and structural typing system that makes code inflexible.
4. The ecosystem lacks high quality frameworks ala Spring that can be used to build applications in such a way that knowledge of structure and style are portable across codebases/companies/etc. Go (like JS) favours a smaller composable library approach which lends itself much better to highly experienced developers than beginners that really do need the help because they are yet to develop good taste. Unfortunately Go mainly caters to beginners so this is a fundamental impedance mismatch between the ecosystem and the users.
5. It actively repels experienced engineers. This is probably the controversial point but it holds true among my social group which I would consider to all be A++ engineers both in intellectual capacity but also real world effectiveness (i.e these guys build the stuff you rely on every day). Why is this so? Well it boils down to that bit about mastery no being rewarding. Even in Java which is admittedly probably the most boring language on the planet there is a very rewarding payout for sticking with the language for a decade and getting exceedingly good at it, you have all the primitives at your fingertips, real threads, powerful reflection, metaprogramming and runtime introspection. What does Go offer? M:N coroutine model, pretty basic profiling capabilities, really shitty (and slow) reflection, runtime with almost no knobs to apply workload specific optimisations, etc. In short for all that time investment to fully peak out you are only marginally better than the next mediocre dev. TLDR: The ceiling is low, you end up surrounded my mediocrity, it's hard to effect change in large codebases as a result, Java/.NET/other langs don't suffer anywhere near as badly as such Go is avoided.
I could go on but these are the main points.
Also I could just be jaded old and grumpy but whatever, this is how I feel about it and everyone is free to be wrong on the Internet.