←back to thread

Go is still not good

(blog.habets.se)
644 points ustad | 8 comments | | HN request time: 0.406s | source | bottom
Show context
the_duke ◴[] No.44983331[source]
I personally don't like Go, and it has many shortcomings, but there is a reason it is popular regardless:

Go is a reasonably performant language that makes it pretty straightforward to write reliable, highly concurrent services that don't rely on heavy multithreading - all thanks to the goroutine model.

There really was no other reasonably popular, static, compiled language around when Google came out.

And there still barely is - the only real competitor that sits in a similar space is Java with the new virtual threads.

Languages with async/await promise something similar, but in practice are burdened with a lot of complexity (avoiding blocking in async tasks, function colouring, ...)

I'm not counting Erlang here, because it is a very different type of language...

So I'd say Go is popular despite the myriad of shortcomings, thanks to goroutines and the Google project street cred.

replies(7): >>44983372 #>>44983413 #>>44983414 #>>44983469 #>>44983501 #>>44983524 #>>44983597 #
zwnow ◴[] No.44983372[source]
What modern language is a better fit for new projects in your opinion?
replies(5): >>44983386 #>>44983445 #>>44985494 #>>44989834 #>>45025592 #
1. aloukissas ◴[] No.44983386[source]
Elixir, with types
replies(5): >>44983510 #>>44983512 #>>44983560 #>>44983795 #>>44984784 #
2. sarchertech ◴[] No.44983510[source]
That doesn’t exist yet. Also Elixir is in no way a replacement for Go.

It can’t match it for performance. There’s no mutable array, almost everything is a linked list, and message passing is the only way to share data.

I primarily use Elixir in my day job, but I just had to write high performance tool for data migration and I used Go for that.

3. zwnow ◴[] No.44983512[source]
This one i can get behind.
4. pmarreck ◴[] No.44983560[source]
I love Elixir but you cannot compile it into a single binary, it is massively concurrent but single-threaded slow, and deployment is still nontrivial.

And lists are slower than arrays, even if they provide functional guarantees (everything is a tradeoff…)

That said, pretty much everything else about it is amazing though IMHO and it has unique features you won’t find almost anywhere else

5. agos ◴[] No.44983795[source]
yeah, if the requirement is "makes it pretty straightforward to write reliable, highly concurrent services that don't rely on heavy multithreading", Elixir is a perfect match.

And even without types (which are coming and are looking good), Elixir's pattern matching is a thousands times better than the horror of Go error handling

6. out_of_protocol ◴[] No.44984784[source]
My vote is for Elixir as well, but it's not a competitor for multiple important reasons. There are some languages in that niche, although too small and immature, like Crystal, Nim. Still waiting for something better.

P.S. Swift, anyone?

replies(2): >>44990412 #>>44990807 #
7. Degorath ◴[] No.44990412[source]
Swift on Linux has been a fairly horrible experience, but the language looks promising.
8. sarchertech ◴[] No.44990807[source]
Last I checked Crystal’s compile time was too slow for me to deal with for anything beyond toy projects.