@@ -1025,56 +1025,6 @@ sys_getprofile_impl(PyObject *module)
10251025 return temp ;
10261026}
10271027
1028- /*[clinic input]
1029- sys.setcheckinterval
1030-
1031- n: int
1032- /
1033-
1034- Set the async event check interval to n instructions.
1035-
1036- This tells the Python interpreter to check for asynchronous events
1037- every n instructions.
1038-
1039- This also affects how often thread switches occur.
1040- [clinic start generated code]*/
1041-
1042- static PyObject *
1043- sys_setcheckinterval_impl (PyObject * module , int n )
1044- /*[clinic end generated code: output=3f686cef07e6e178 input=7a35b17bf22a6227]*/
1045- {
1046- if (PyErr_WarnEx (PyExc_DeprecationWarning ,
1047- "sys.getcheckinterval() and sys.setcheckinterval() "
1048- "are deprecated. Use sys.setswitchinterval() "
1049- "instead." , 1 ) < 0 ) {
1050- return NULL ;
1051- }
1052-
1053- PyThreadState * tstate = _PyThreadState_GET ();
1054- tstate -> interp -> check_interval = n ;
1055- Py_RETURN_NONE ;
1056- }
1057-
1058- /*[clinic input]
1059- sys.getcheckinterval
1060-
1061- Return the current check interval; see sys.setcheckinterval().
1062- [clinic start generated code]*/
1063-
1064- static PyObject *
1065- sys_getcheckinterval_impl (PyObject * module )
1066- /*[clinic end generated code: output=1b5060bf2b23a47c input=4b6589cbcca1db4e]*/
1067- {
1068- if (PyErr_WarnEx (PyExc_DeprecationWarning ,
1069- "sys.getcheckinterval() and sys.setcheckinterval() "
1070- "are deprecated. Use sys.getswitchinterval() "
1071- "instead." , 1 ) < 0 ) {
1072- return NULL ;
1073- }
1074-
1075- PyThreadState * tstate = _PyThreadState_GET ();
1076- return PyLong_FromLong (tstate -> interp -> check_interval );
1077- }
10781028
10791029/*[clinic input]
10801030sys.setswitchinterval
@@ -1990,8 +1940,6 @@ static PyMethodDef sys_methods[] = {
19901940 SYS_INTERN_METHODDEF
19911941 SYS_IS_FINALIZING_METHODDEF
19921942 SYS_MDEBUG_METHODDEF
1993- SYS_SETCHECKINTERVAL_METHODDEF
1994- SYS_GETCHECKINTERVAL_METHODDEF
19951943 SYS_SETSWITCHINTERVAL_METHODDEF
19961944 SYS_GETSWITCHINTERVAL_METHODDEF
19971945 SYS_SETDLOPENFLAGS_METHODDEF
@@ -2430,7 +2378,6 @@ getrefcount() -- return the reference count for an object (plus one :-)\n\
24302378getrecursionlimit() -- return the max recursion depth for the interpreter\n\
24312379getsizeof() -- return the size of an object in bytes\n\
24322380gettrace() -- get the global debug tracing function\n\
2433- setcheckinterval() -- control how often the interpreter checks for events\n\
24342381setdlopenflags() -- set the flags to be used for dlopen() calls\n\
24352382setprofile() -- set the global profiling function\n\
24362383setrecursionlimit() -- set the max recursion depth for the interpreter\n\
0 commit comments