| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
I've fixed the failing macOS CI for you :) |
Sorry, something went wrong.
…onGH-128081) remove unnecessary __init__ method from Enum Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
…onGH-128081) remove unnecessary __init__ method from Enum Co-authored-by: Peter Bierma <zintensitydev@gmail.com>
| Back | FazBrowse Home | New Git URL |
Enum gained an __init__ method in 3.11 which just passes:
That was added in #30582. One person questioned it at the time, but there was no response. The best I can figure is that it was related to special handling of __init__ in EnumType.__dir__, which you can see here:
cpython/Lib/enum.py
Lines 768 to 779 in 3852269
That special handling of __init__ was removed by #30677 prior to 3.11 being released, which leaves no plausible function to Enum.__init__ that I can see. It muddies introspection of the type, so I think we should remove it if that's really the case.