mirror of
https://github.com/python/cpython.git
synced 2025-07-08 03:45:36 +00:00
bpo-37146: Deactivate opcode cache only when using huntrleaks in the test suite (GH-24643)
This commit is contained in:
parent
e8f5ddd33e
commit
af5fa13ef6
5 changed files with 49 additions and 11 deletions
|
@ -1958,6 +1958,20 @@ sys_getandroidapilevel_impl(PyObject *module)
|
|||
#endif /* ANDROID_API_LEVEL */
|
||||
|
||||
|
||||
/*[clinic input]
|
||||
sys._deactivate_opcache
|
||||
|
||||
Deactivate the opcode cache permanently
|
||||
[clinic start generated code]*/
|
||||
|
||||
static PyObject *
|
||||
sys__deactivate_opcache_impl(PyObject *module)
|
||||
/*[clinic end generated code: output=00e20982bd012122 input=501eac146735ccf9]*/
|
||||
{
|
||||
_PyEval_DeactivateOpCache();
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
|
||||
|
||||
static PyMethodDef sys_methods[] = {
|
||||
/* Might as well keep this in alphabetic order */
|
||||
|
@ -2011,6 +2025,7 @@ static PyMethodDef sys_methods[] = {
|
|||
SYS_GET_ASYNCGEN_HOOKS_METHODDEF
|
||||
SYS_GETANDROIDAPILEVEL_METHODDEF
|
||||
SYS_UNRAISABLEHOOK_METHODDEF
|
||||
SYS__DEACTIVATE_OPCACHE_METHODDEF
|
||||
{NULL, NULL} /* sentinel */
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue