3 ms·
Type annotations are included in Python 3: http://www.python.org/dev/peps/pep-3107/ http://www.python.org/dev/peps/pep-3107/ (More specifically, Python 3 incl
by nostrademons 14y ago
Type annotations are included in Python 3:
http://www.python.org/dev/peps/pep-3107/ http://www.python.org/dev/peps/pep-3107/
(More specifically, Python 3 includes generic "function annotations" that look a lot like type declarations do in other languages, but can be used for other purposes as well. The idea is to offload typechecking to a library, so you could eg. include type inference, dimensional analysis, preconditions or DBC, etc. as desired.)