Staging
v0.5.1
https://github.com/python/cpython
Revision 3f9eee6eb4b25fe1926eaa5f00e02344b126f54d authored by Eric Snow on 15 September 2017, 22:35:20 UTC, committed by GitHub on 15 September 2017, 22:35:20 UTC
The concrete PyDict_* API is used to interact with PyInterpreterState.modules in a number of places. This isn't compatible with all dict subclasses, nor with other Mapping implementations. This patch switches the concrete API usage to the corresponding abstract API calls.

We also add a PyImport_GetModule() function (and some other helpers) to reduce a bunch of code duplication.
1 parent e82c034
History
Tip revision: 3f9eee6eb4b25fe1926eaa5f00e02344b126f54d authored by Eric Snow on 15 September 2017, 22:35:20 UTC
bpo-28411: Support other mappings in PyInterpreterState.modules. (#3593)
Tip revision: 3f9eee6
File Mode Size
darwin
libffi_msvc
libffi_osx
_ctypes.c -rw-r--r-- 177.1 KB
_ctypes_test.c -rw-r--r-- 16.0 KB
_ctypes_test.h -rw-r--r-- 82 bytes
callbacks.c -rw-r--r-- 16.9 KB
callproc.c -rw-r--r-- 52.3 KB
cfield.c -rw-r--r-- 43.4 KB
ctypes.h -rw-r--r-- 12.9 KB
ctypes_dlfcn.h -rw-r--r-- 459 bytes
malloc_closure.c -rw-r--r-- 2.7 KB
stgdict.c -rw-r--r-- 19.7 KB

back to top