Skip to content
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

Submission for SC consideration: PEP 673 -- Self Type #95

Closed
pradeep90 opened this issue Jan 12, 2022 · 2 comments
Closed

Submission for SC consideration: PEP 673 -- Self Type #95

pradeep90 opened this issue Jan 12, 2022 · 2 comments

Comments

@pradeep90
Copy link

Please consider PEP 673 for inclusion in Python 3.11. This is primarily of interest to users of static type checkers. It provides a simple and intuitive way to annotate methods that accept or return an instance of their class.

The PEP has been discussed at length in typing sig and on the draft doc. We have also notified python-dev.

There are reference implementations of the type checking part in Pyright and Mypy. There is also an implementation of the Self special form in typing_extensions.py.

CC: @Gobot1234 @JelleZijlstra

https://www.python.org/dev/peps/pep-0673/

@brettcannon
Copy link
Member

Thanks! I will add it to our review queue.

@encukou
Copy link
Member

encukou commented Jan 24, 2022

Accepted in https://mail.python.org/archives/list/python-dev@python.org/thread/J7BWL5KWOPQQK5KFWKENVLXW6UGSPTGI/
Congratulations!

@encukou encukou closed this as completed Jan 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants