mirror of
https://github.com/python/cpython.git
synced 2025-10-09 16:34:44 +00:00
Call super in Generic.__init_subclass__ (#6356)
This commit is contained in:
parent
2eeac269dd
commit
ee566fe526
2 changed files with 20 additions and 0 deletions
|
@ -850,6 +850,7 @@ class Generic:
|
|||
return _GenericAlias(cls, params)
|
||||
|
||||
def __init_subclass__(cls, *args, **kwargs):
|
||||
super().__init_subclass__(*args, **kwargs)
|
||||
tvars = []
|
||||
if '__orig_bases__' in cls.__dict__:
|
||||
error = Generic in cls.__orig_bases__
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue