News for hackers. Stuff that matters.
Re:Thoughts on Go vs. Rust vs. Zig by 9rx on Friday December 05, 2025 @08:29AM (#46161004)
> The error type in go is literally just a string

No, like I said before, it's literally an interface. Hell, your next line even proves it. If it were a string, it would be defined as:

    type error string
But as you've pointed out yourself, that's not its definition at all.

> So i dont know what your talking about then.

I guess that's what happens when you don't even have a basic understanding of programming. Errors are intended to be complex types; to capture all the relevant information that pertains to the error. https://go.dev/play/p/MhQY_6eT1Ir At very least a sentinel value. If your error is just a string, you're doing something horribly wrong — or, charitably, trying to shoehorn Go into scripting tasks. But in that case you'd use Go's exception handlers, which bundles the stack trace and all alongside the string, so... However, if your workload is script in nature, why not just use Python? That's what it was designed for. Different tools for different jobs.

Re:Thoughts on Go vs. Rust vs. Zig by tayo42 on Friday December 05, 2025 @09:37AM (#46161842)
This guy can't help his self except to act like an ass
Re:Thoughts on Go vs. Rust vs. Zig by 9rx on Friday December 05, 2025 @09:44AM (#46161934)
It is always curious when a comment on the internet is anthropomorphized. Where is the logic found in that?