162 karma · joined November 30, 2025
There would be real value in a language which would have both.
Error values are perfect for un-exceptional errors, e.g. some states of a business logic. The name that the user entered is invalid, some record is missing from the database, the user's country is not supported. Cases that are part of the business domain and that _must_ be handled, and therefore explicitly modeled.
Then there is the grey area of errors that one might expect (so not truly exceptional) but are not related to the business logic. These could be for example network timeouts, unexpected HTTP errors (like 503), etc. For those, there is often no explicit handling in the domain that makes sense. So it's convenient to just throw an exception, let it automatically "bubble" to the highest level (e.g. the HTTP controller) and just return some generic error (such as HTTP 500).
There are also truly exceptional cases, that you really shouldn't encounter in your program, such as null-dereferences, invalid array index access, division by zero, etc. These indicate a bug in the code (and might be introduced explicitly with assert-style checks). The program is in an unknown, compromised state, so there's really nothing left to do than throw an exception or panic. An error value makes very little sense in this case.
I often have the discussion with friends, why a division operator, or an array access, doesn't return a `Result` type in nice languages such as Rust? Surely, if they care about error values, then each operation that can fail, must return a `Result` rather than panic (throw an exception). It is an interesting through experiment at least.
I don't know about Rust, but a very important difference between Java exceptions and Go panics, is that a Go panic kills the entirely process (unless recovered), whereas a Java exception only terminates the thread (unless caught).
It's a little off-topic, but I wanted to clarify that for passer-bys who might not know.
That is to say, keeping anything historical has its limits. If we always keep everything historical, we will keep literally everything, and the planet will be quite full pretty quickly, with no place to build anything.
We should be careful to preserve truly historically relevant things. But most historical things are just old trash...
Retirement has the definition to stop working. One could argue that another definition may be that you reach an older age and start receiving pension payouts (regardless of whether you keep working or not).
But having a passive income alone simply doesn't mean retirement.
It would be really hard to believe that somehow Apple has found some magic formula to make their apps 100x smaller than Google and Microsoft.
Much more likely is that the reporting by the OS is off somehow (probably most of the app functionality is tied up in shared resources counted towards system files, and not counted towards the app's size).
With respect, I would expect more from articles posted on Hacker News. More thorough research, and in fact an answer to the question.
Can you explain how you see a causation between religion and marriage success?
I'm past the age where I can (or rather should have) kids and I have to say, the past decade or so I'm more and more thinking that people SHOULD have kids to have (more) meaning in their life. Put it another way, I've begun thinking that having children is a nice way to have a default baseline of meaning in your life. I really see that with all my friends, who all have kids.
Some languages (e.g. Java) include a stack trace when reporting an error, which is extremely useful when logging the error. It shows at exactly which point in the code the error was generated, and what the full call stack was to get there.
It's a real shame that "modern" languages or "low level" languages (e.g. Go, Rust) don't include this out of the box, it makes troubleshooting errors in production much more difficult, for exactly the reason you mention.
key := make([]byte, 32)
defer scramble(&key)
// do all the secret stuff
Unless I don't understand the problem correctly.But it is true that at any time they could make using an email address or phone number mandatory, and then creating an Advent of Code account will be gated behind that.
This is the appeal to worse problems fallacy. Both are problems, both need to be addressed.