Skip to content

Commit

Permalink
Fix __init_subclass__ using self instead of class (#31135)
Browse files Browse the repository at this point in the history
  • Loading branch information
GBeauregard committed Feb 5, 2022
1 parent fea7290 commit 2f077b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Lib/typing.py
Expand Up @@ -349,7 +349,7 @@ class _Final:

__slots__ = ('__weakref__',)

def __init_subclass__(self, /, *args, **kwds):
def __init_subclass__(cls, /, *args, **kwds):
if '_root' not in kwds:
raise TypeError("Cannot subclass special typing classes")

Expand Down

0 comments on commit 2f077b6

Please sign in to comment.