[issue38333] add type signatures to library function docs
paul rubin
report at bugs.python.org
Thu Oct 3 02:58:07 EDT 2019
paul rubin <phr-pythonbugs at nightsong.com> added the comment:
I don't think we're going to accomplish anything continuing the eternal static-vs-dynamic debate, which in Python's case has already been resolved by adding optional static typing. It's a done deal, and the issue here is just how to document it. Erlang (via the Erlang Dialyzer), Clojure, and Racket have all been down a similar road and gained some value from it.
Haskell's Maybe type (its version of Option) works fine. In Python the convention of returning None for a missing value is not great, but we are stuck with it and Option[whatever] is helpful.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue38333>
_______________________________________
More information about the Python-bugs-list
mailing list