gh-119180: Lazily wrap annotations on classmethod and staticmethod (#… · python/cpython@d28afd3 · GitHub
Skip to content

Commit d28afd3

Browse files
gh-119180: Lazily wrap annotations on classmethod and staticmethod (#119864)
1 parent 80a4e38 commit d28afd3

3 files changed

Lines changed: 138 additions & 3 deletions

File tree

Lib/test/test_descr.py

Lines changed: 36 additions & 2 deletions
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
:func:`classmethod` and :func:`staticmethod` now wrap the
2+
:attr:`__annotations__` and :attr:`!__annotate__` attributes of their
3+
underlying callable lazily. See :pep:`649`. Patch by Jelle Zijlstra.

Objects/funcobject.c

Lines changed: 99 additions & 1 deletion

0 commit comments

Comments
 (0)