A new PEP for Python 3.11 proposes to introduce a new special form called Self exported from the typing module.
https://docs.google.com/document/d/1ujuSMXDmSIOJpiZyV7mvBEC8P-y55AgSzXcvhrZciuI/edit
Pyright already implements this in an implicit manner, inferring the type of self and cls parameters when they are unannotated, so it should be easy to prototype this new functionality.
A new PEP for Python 3.11 proposes to introduce a new special form called
Selfexported from thetypingmodule.https://docs.google.com/document/d/1ujuSMXDmSIOJpiZyV7mvBEC8P-y55AgSzXcvhrZciuI/edit
Pyright already implements this in an implicit manner, inferring the type of
selfandclsparameters when they are unannotated, so it should be easy to prototype this new functionality.