3 ms·
"Each error scope stores only the first error it captures; any further errors it captures are silently ignored." is one of the worst design decisions I've ever
by kevingadd 3y ago
"Each error scope stores only the first error it captures; any further errors it captures are silently ignored." is one of the worst design decisions I've ever seen. That means if code is expecting one error to occur, any unexpected errors that occur after it in the scope are unobservable. The only way to handle that would be to push/pop tons of scopes.
How hard is it to make an array of errors instead of a single slot? What's the upside of this other than laziness?
- johncolanduoni 3y agoThese kinds of errors are usually programmer errors that cause literally hundreds of downstream errors because they put an object later used by other code in an invalid state. In these cases only the first error is particularly useful, the rest are just noise.
- xnorswap 3y agoThe worst? No, that belongs to VB: > On Error Resume Next Literally, "Ignore the error, and continue as if nothing bad had happened". That's the worst design decision ever when it comes to error handling. Only storing the first error is bad, but that's why they describe it as a problem with WebGL that they solve in WebGPU by using a stack.