SIGN IN SIGN UP

bpo-40549: posixmodule.c uses defining_class (GH-20075)

Pass PEP 573 defining_class to os.DirEntry methods. The module state
is now retrieve from defining_class rather than Py_TYPE(self), to
support subclasses (even if DirEntry doesn't support subclasses yet).

* Pass the module rather than defining_class to DirEntry_fetch_stat().
* Only get the module state once in _posix_clear(),
  _posix_traverse() and _posixmodule_exec().
V
Victor Stinner committed
97f33c35445e6d67df24dcbafef7b78333feb778
Parent: e77d428
Committed by GitHub <noreply@github.com> on 5/14/2020, 4:05:58 PM