bpo-46269: [Enum] remove special-casing of __new__
in EnumType.__dir__
(GH-30421)
This commit is contained in:
parent
43aac29cbb
commit
817a6bc9f7
@ -652,10 +652,6 @@ class EnumType(type):
|
||||
# if and only if they have been user-overridden
|
||||
enum_dunders = set(filter(_is_dunder, enum_dict))
|
||||
|
||||
# special-case __new__
|
||||
if self.__new__ is not first_enum_base.__new__:
|
||||
add_to_dir('__new__')
|
||||
|
||||
for cls in mro:
|
||||
# Ignore any classes defined in this module
|
||||
if cls is object or is_from_this_module(cls):
|
||||
|
@ -0,0 +1 @@
|
||||
Remove special-casing of ``__new__`` in :meth:`enum.Enum.__dir__`.
|
Loading…
x
Reference in New Issue
Block a user