8000 Support for `declared_type`, to give types to decorated functions by sixolet · Pull Request #3291 · python/mypy · GitHub
[go: up one dir, main page]

Skip to content

Support for declared_type, to give types to decorated functions #3291

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 13 commits into from
Prev Previous commit
Next Next commit
lint
  • Loading branch information
sixolet committed May 1, 2017
commit c739cefb935bddf0709d8da50f9c86c3c9839d24
1 change: 1 addition & 0 deletions extensions/mypy_extensions.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ class Point2D(TypedDict):
# Return type that indicates a function does not return
class NoReturn: pass


def decorated_type(t):
"""Declared the decorated type of a decorated item"""
# Return the identity function -- calling this should be a noop
Expand Down
0