2 ms·
One thing a C-like goto has over exceptions is that you can only jump around within a single lexical scope. That restriction is a big win for readability. Exce
by mumblemumble 5y ago
One thing a C-like goto has over exceptions is that you can only jump around within a single lexical scope. That restriction is a big win for readability.
Exceptions use a dynamic scope to decide where to jump to, so, in the general case, it's a lot harder to understand how they will affect program behavior by simply reading the code. That's a major reason why using exceptions for non-exceptional control flow is widely considered to be evil.