Exception handling transfers control from an operation that signals an exceptional condition to a matching handler. A parser can signal a malformed input instead of returning an ordinary result; a surrounding handler can report or recover from that case. Propagation may unwind intervening call frames, so cleanup constructs specify what happens to resources during exit. Checked and unchecked exception rules differ by language. Catching an exception does not itself restore an invariant damaged before it was raised, and silently discarding every exception can hide a failed computation.
// Target: computer-science.bigb
New to topics? Read the docs here!