Comment

Comment by zoky

> Panic isn't supposed to be "I'm not sure what to do now, maybe my caller will know?".

So panic is supposed to be “I’m not sure what to do now, I don’t care if my caller knows”?

No process running outside of kernel space ever has any business panicking. Throw an error and move on with your life (or don’t, that’s fine too) but don’t punish your caller by forcing it to crash because you failed to foresee X, Y, or Z circumstances.

parent zoky 3 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton