mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
bpo-43827: Make arguments to abc.ABCMeta.__new__ pos-only (#25385)
To avoid conflicts with `__init__subclass__`.
This commit is contained in:
parent
a95138b2c5
commit
42fee931d0
4 changed files with 16 additions and 1 deletions
|
@ -102,7 +102,7 @@ else:
|
|||
implementations defined by the registering ABC be callable (not
|
||||
even via super()).
|
||||
"""
|
||||
def __new__(mcls, name, bases, namespace, **kwargs):
|
||||
def __new__(mcls, name, bases, namespace, /, **kwargs):
|
||||
cls = super().__new__(mcls, name, bases, namespace, **kwargs)
|
||||
_abc_init(cls)
|
||||
return cls
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue