Erlend Egeberg Aasland <erlend.aasl...@innova.no> added the comment:
Alternative approach: Add _PyType_DisabledNew to Include/cpython, and add {Py_tp_new, _PyType_DisabledNew} slot to affected types. Diff attached. See GH discussion: - https://github.com/python/cpython/pull/25653#issuecomment-827383246 - https://github.com/python/cpython/pull/25653#issuecomment-827390034 ---------- Added file: https://bugs.python.org/file49992/disablednew.diff _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue43916> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com