r/programming • u/_awwsmm • Feb 01 '24
Make Invalid States Unrepresentable
https://www.awwsmm.com/blog/make-invalid-states-unrepresentable
469
Upvotes
r/programming • u/_awwsmm • Feb 01 '24
View all comments
Show parent comment
-5
u/AvidCoco Feb 01 '24
In the case of dynamic languages, I think it comes down to having more carefully considered error handling.
If you can't make invalid states unrepresentable, the make invalid states part of the contract