4 ms·
Saying it's so doesn't make it true. You can declare that an error is simply a special value returned and expect people to check for that value all over the pla
by lectrick 12y ago
Saying it's so doesn't make it true. You can declare that an error is simply a special value returned and expect people to check for that value all over the place, or you can declare that errors are (literally) "exceptions" and should therefore throw.
- NateDad 12y agoYou can ignore error values returned just like you can ignore the numeric value returned from atoi. That's the point. They're just values. You are the programmer, it's your job to decide what to do with any particular value returned by a function.
- prodigal_erik 12y agoIt's also my job to decide what the square root of "fish" should be. What I do is use a declaration to mechanically verify that cannot ever happen. I never ever want to silently ignore an error, so why shouldn't I be able to declare that as well?