gh-104066: Improve performance of hasattr for module objects (#104063)

This commit is contained in:
Itamar Ostricher 2023-05-04 07:50:26 -07:00 committed by GitHub
parent c9ecd3ee75
commit fdcb49c36b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 78 additions and 29 deletions

View file

@ -36,6 +36,9 @@ static inline PyObject* _PyModule_GetDict(PyObject *mod) {
return dict;
}
PyObject* _Py_module_getattro_impl(PyModuleObject *m, PyObject *name, int suppress);
PyObject* _Py_module_getattro(PyModuleObject *m, PyObject *name);
#ifdef __cplusplus
}
#endif