You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think the most salient point is the Principle of Least Astonishment. Since exceptions can't reasonably be indicated in type signatures, using exceptions requires developers memorizing which functions may throw them as a part of their "normal" flow. That's a recipe for astonishment - especially if the implicit intentional-exception-throwing contract changes unexpectedly.
The text was updated successfully, but these errors were encountered:
Overview
Speaking generally: https://softwareengineering.stackexchange.com/questions/189222/are-exceptions-as-control-flow-considered-a-serious-antipattern-if-so-why is a good summary of my perspective here.
I think the most salient point is the Principle of Least Astonishment. Since exceptions can't reasonably be indicated in type signatures, using exceptions requires developers memorizing which functions may throw them as a part of their "normal" flow. That's a recipe for astonishment - especially if the implicit intentional-exception-throwing contract changes unexpectedly.
The text was updated successfully, but these errors were encountered: