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
The napoleon extension to Sphinx (which we use for documentation) accepts PEP-484 type hints as well as types in the docstrings. E.g., these are the same:
deffoo(a):
""" foo the a Args: a (int): a bar """returna*2deffoo(a: int):
""" foo the a Args: a: a bar """returna*2
The type hints in the latter can also be used by static analysis tools for type checking, and maybe other things in the future. We should aim to (maybe gradually) incorporate type hints wherever applicable throughout the PyDelphin codebase.
The text was updated successfully, but these errors were encountered:
The napoleon extension to Sphinx (which we use for documentation) accepts PEP-484 type hints as well as types in the docstrings. E.g., these are the same:
The type hints in the latter can also be used by static analysis tools for type checking, and maybe other things in the future. We should aim to (maybe gradually) incorporate type hints wherever applicable throughout the PyDelphin codebase.
The text was updated successfully, but these errors were encountered: