4 ms·
You clearly aren't caught up with the latest changes in python. The interpreter doesn't have static checks, but the language supports external tooling to do thi
by crimsonalucard 8y ago
You clearly aren't caught up with the latest changes in python. The interpreter doesn't have static checks, but the language supports external tooling to do this.
Look up type annotations for python 3 and the mypy external type checker.
Static type checking is now a very real thing with modern versions of python.
Additionally it is possible to code the match function to implement the functionality I am talking about during runtime instead of compile time. Definitely not irrelevant.
- paulddraper 8y ago> Additionally it is possible to code the match function to implement the functionality I am talking about during runtime instead of compile time. Maybe, but I'm not sure there's more value in that.
- crimsonalucard 8y agoHaving match crash immediately helps you identify the branch error without explicitly writing a test case for it. It is equivalent to raising an exception.