Go has very weak compiler and completely falls apart on anything but trivial code. If you care about reaching performance ceiling while staying with higher level language - use C#.
Good programmers know better than to confuse Go for a systems programming language.
Honestly, I enjoy programming in Go and been using it on a daily basis for the last few years. Most importantly, when it comes to performance it's often not the language that matters but how you structure your code. It's very much possible to build a terrible C++ program which thrashes memory and will be very slow. And I feel like Go is actually lacking those nice data-oriented libraries.
Little reason to use Go here. C# is a much better language at allowing you to tactically write high-performance low-level code where it matters and relying on higher level abstractions when it's not (struct generics are just like in Rust allowing you to expend a little effort for achieving zero-cost abstractions, although not as convenient as just using objects everywhere).
From my experience, Go is much more boiler-plate-ish than C#. They wanted a very simple language with very simple libraries. But if the functionality is not builtin, you have to implement it yourself. Go is faster to learn but it will take more time to develop something.
I think that the argument here is that the c# environment is much bigger and that the programming level is at a higher level. That these are things that are often made at a sacrifice for performance but that that's not the case here, so why use Go at all
When Go first came out, it was better than C# in terms of support for concurrency, stand-alone binaries, and cross-platform. It seems that C# has done a lot of catching up since then, though.
Go was created for correctness. It is strongly, statically typed, it won't compile if there are unused imports or variables, and it won't compile either if you don't free up resources after usage. C/C++ don't do that and have UBs.
Go is in the same ballpark than C#: a modernized C with GC, good productivity although not as good as a scripting language, and good performance although not as good as ANSI C. They're popular because they stand in that sweet spot.
Python is easier than Go or C# to pick up, but it's also 20x slower than C rather than 2-3x.
If you think that Go is a better choice than C#, you probably spend too much time watching tech influencers on youtube and twitch and too little time programming and getting familiar with the technologies they spread FUD about.
Go is inferior to C# in every possible dimension: performance, package management, terseness and expressiveness - Go brings notoriously more boilerplate, Go has poorer ecosystem for writing web applications, worse ORMs and worse tools for troubleshooting advanced issues in production - the list goes on.
There are companies that do C# disservice, but you're going to hate to see what they will do with Go instead.
C# is a really bad example to say Go is good. I always felt people were too lazy to explore proper alternatives. People don't like something in C# or Java and jump to go because you can learn it in a day instead of investing 2 days to write in Rust or Erlang or Haskell or Ocaml or whatever. Go is just a better C with coroutines
This is exactly what crossed it off my list. I am interested in a better language than C++ for writing really fast, low-level code but I already have tons of good options for higher-level code.
I imagine using Go to write high-performance code or interact well with system libraries is not easier or simpler than a C++ approach, and certainly having worse results.
Also, the comparison to CS/JS seems unfair as Go is not just a syntax change to C++ and has very different a programming style and design goals.
Hopefully Go being such a bare bones language with unsound features will tire you out soon enough to follow the sibling comment in moving to C# instead :)
Not really. I've written a bit of Go and a lot of C#, and can tell you from my experience that they are very different tools. C# is a very feature rich language like C++, while avoiding the majority of the 'gotchas' in C++ (in obvious areas such as memory management). Generic types, Abstract Classes, LINQ etc. all can be very productive if you know how/when to use them.
Golang is much more minimal. It does have some very nice concurrency features that could be a big win for some users. C# is fine at concurrency, but Golang's way of integrating it into the language is definitely more streamlined.
IMO pick the best tool for the job. In many cases, large enterprise pieces of software that want the mature tooling of C# will benefit from .NET Native. /rant
Good programmers know better than to confuse Go for a systems programming language.
reply