mirror of https://github.com/python/cpython
19d246745d
Handling zero-argument super() in __init_subclass__ and __set_name__ involved moving __class__ initialisation to type.__new__. This requires cooperation from custom metaclasses to ensure that the new __classcell__ entry is passed along appropriately. The initial implementation of that change resulted in abruptly broken zero-argument super() support in metaclasses that didn't adhere to the new requirements (such as Django's metaclass for Model definitions). The updated approach adopted here instead emits a deprecation warning for those cases, and makes them work the same way they did in Python 3.5. This patch also improves the related class machinery documentation to cover these details and to include more reader-friendly cross-references and index entries. |
||
---|---|---|
.. | ||
clinic | ||
Python-ast.c | ||
README | ||
_warnings.c | ||
asdl.c | ||
ast.c | ||
bltinmodule.c | ||
ceval.c | ||
ceval_gil.h | ||
codecs.c | ||
compile.c | ||
condvar.h | ||
dtoa.c | ||
dup2.c | ||
dynamic_annotations.c | ||
dynload_aix.c | ||
dynload_dl.c | ||
dynload_hpux.c | ||
dynload_next.c | ||
dynload_shlib.c | ||
dynload_stub.c | ||
dynload_win.c | ||
errors.c | ||
fileutils.c | ||
formatter_unicode.c | ||
frozen.c | ||
frozenmain.c | ||
future.c | ||
getargs.c | ||
getcompiler.c | ||
getcopyright.c | ||
getopt.c | ||
getplatform.c | ||
getversion.c | ||
graminit.c | ||
import.c | ||
importdl.c | ||
importdl.h | ||
importlib.h | ||
importlib_external.h | ||
makeopcodetargets.py | ||
marshal.c | ||
modsupport.c | ||
mysnprintf.c | ||
mystrtoul.c | ||
opcode_targets.h | ||
peephole.c | ||
pyarena.c | ||
pyctype.c | ||
pyfpe.c | ||
pyhash.c | ||
pylifecycle.c | ||
pymath.c | ||
pystate.c | ||
pystrcmp.c | ||
pystrhex.c | ||
pystrtod.c | ||
pythonrun.c | ||
pytime.c | ||
random.c | ||
sigcheck.c | ||
strdup.c | ||
structmember.c | ||
symtable.c | ||
sysmodule.c | ||
thread.c | ||
thread_foobar.h | ||
thread_nt.h | ||
thread_pthread.h | ||
traceback.c | ||
wordcode_helpers.h |
README
Miscellaneous source files for the main Python shared library