File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -579,8 +579,14 @@ Language Features
579579-----------------
580580
581581Use the latest language features available, even for stubs targeting older
582- Python versions. Do not use quotes around forward references and do not use
583- ``__future__ `` imports. See :ref: `stub-file-syntax ` for more information.
582+ Python versions. For example, Python 3.7 added the ``async `` keyword (see
583+ :pep: `492 `). Stubs should use it to mark coroutines, even if the implementation
584+ still uses the ``@coroutine `` decorator. On the other hand, the ``type `` soft
585+ keyword from :pep: `695 `, introduced in Python 3.12, should not be used in stubs
586+ until Python 3.11 reaches end-of-life in October 2027.
587+
588+ Do not use quotes around forward references and do not use ``__future__ ``
589+ imports. See :ref: `stub-file-syntax ` for more information.
584590
585591Yes::
586592
You can’t perform that action at this time.
0 commit comments