Live data from Hacker News

Just Use Go

blainsmith.com

81–90 of 238 posts

Re: Just Use Go

#81
> `if err != nil` is the feature, not the bug. It forces you to look at every place something can go wrong and decide what to do about it

Haven't really used Go, but can't someone just `result, _ := foo()` and go on using `result`, not checking any errors?

The way Rust does it seems closer to forcing you to handle any errors in order to obtain the result (though it is still easy to just `.unwrap()` without properly thinking about it).

Re: Just Use Go

#82
post #53

I would like someone to explain me Go. Really, I will use strong words but that's really what I feel. The syntax changes a lot from the C one, and I can't see any reason for it. To me, it looks unstructured, with the lack of colons for example. It ignores memory safety, it feels like it ignored all of the typing system research since C, no discriminated union, and structures and types in general are heavy to write. I…

I like it because I have more control over the size and layout of my memory structures than many GC languages, and the goroutine/channel data flow design model lets me use all the cores pretty evenly without having to worry about mutexes or subtleties. Pretty easy to get into the 100k request per second performance regime without special tweaking. I tend to either write long lived servers where the performance per container directly affects the cost, or analytics sort of Calais where I want my laptop to use 1/2 or 3/4 of its cores and get a faster answer from scraping 10M whatevers.

Re: Just Use Go

#83

Go, similar to Rust, has a horrible ecosystem, IMHO. I want to like it, but they already broke backwards compatibility with older systems (try to get the Go compiler running on a slightly older OS X, f.ex.), and for a compiler that's a no-go to me.

I regret to inform you, but the post was not about maintaining old systems, it was about simplicity in creating services using a language purpose-designed for creating services. The modern underlying os/docker image was kind of a baked-in assumption.

The post was about Go and uses the "The boring choice is the right choice." point at the end. But a compiler that's so quick to abandoned previously perfectly fine supported systems, and basically is bleeding edge, is anything but the "boring right choice". I personally prefer long term stability in the toolchains I use for my projects at least.

Re: Just Use Go

#84
Hey dipshit,

Maybe I develop games. Maybe I develop IoT devices. I might even be working in a high-stakes environment where formal verification is needed, who knows.

Whatever the case may be, we all have our reasons for choosing certain technologies. Not everyone is building run-of-the-mill 'backends' after all.

So please, let's stuff that neckbeardy arrogance away. It serves no purpose and distracts from the discussion.

Thanks.

P. s. I develop my backends in go.

Re: Just Use Go

#85

Why is this flagged? Because of the swearing? Cause there have been previous posts with swearing in them? Or do people in general hate Go so much? I know the OP said dont use external libraries, but I love bubble tea (And their related libs), they are a great reason to use Go for TUI that said, I only use Go for hobby projects, I dont know how good it feels if you have to use it for work 40 hours a week

It's likely being flagged because people believe it's more AI-written than not

Let me copy paste my other comment:

"This is getting really fucking irritating. Every 3rd comment on every HN post is "This is LLM", which has become a proxy for "I dont like it so it must be llm"

Re: Just Use Go

#86

Go, similar to Rust, has a horrible ecosystem, IMHO. I want to like it, but they already broke backwards compatibility with older systems (try to get the Go compiler running on a slightly older OS X, f.ex.), and for a compiler that's a no-go to me.

Isn't that the same thing that Homebrew does? It only has CI for the last couple of Mac OS X versions. Seems like this is more of an issue with Mac OS X architecture than Go.

Dunno about Homebrew (haven't used that since many years for various reasons), but Apple is certainly pushing things in a way that makes 3rd party developers quickly abandon old systems too. That's true. At least lots of 3rd party developers are very quick to give up if their new Xcode will not cooperate.

Re: Just Use Go

#87
post #6

> The boring choice is the right choice. It always was. Right, absolutely correct, Java is a great choice, so why does this post keep going on about Go?

My big issue with Go is, the language just isn't that great. Zero values instead of sum types, reflection instead of proper macros, a mediocre module system…

Java's warts are far worse than Go. Everything is nullable. There's no module system to speak of. It's so IDE-dependant.

I agree with the spirit of "use boring technology." So thank god Go is boring enough that I don't have to write Java anymore.

Re: Just Use Go

#88
post #34

I know it doesn't matter, but... ...who invented this letter-casing convention? import ( "embed" "html/template" "net/http" ) //go:embed templates/*.html var files embed.FS var tmpl = template.Must(template.ParseFS(files, "templates/*.html")) why is the name of a module lower-cased but the names of functions accessed via its namespace upper-cased? how does this make sense?

[deleted]

Re: Just Use Go

#89
The best feature of Gon is that it is boring.

You cose something and if you don't use some weird 3rd party packages (Go stdlib is quite complete) you can check that code again in 3 years and will still work.

Re: Just Use Go

#90

I like go, but a lot of little things stop me from loving it. Like, enums. I get a lot out of the box when I use an enum in Java or Kotlin. Converting to/from a String is trivial. Type safety ... exists. I can do that in Go, but I have to hack it in, for every single enum type I want to represent. Enums are not a thing in the language, which means its easier to keep the language in your brain all at once, but at the…

I really wish they had added Enums instead of the stupid generics.
Post reply on HN