mirror of
https://github.com/python/cpython.git
synced 2025-08-01 07:33:08 +00:00
Deprecate the timing module for removal in Python 3.0.
This commit is contained in:
parent
ac861b5a17
commit
bb141bb1f4
3 changed files with 8 additions and 0 deletions
|
@ -54,5 +54,9 @@ static PyMethodDef timing_methods[] = {
|
|||
|
||||
PyMODINIT_FUNC inittiming(void)
|
||||
{
|
||||
if (PyErr_WarnPy3k("the timing module has been removed in "
|
||||
"Python 3.0; use time.clock() instead", 2) < 0)
|
||||
return;
|
||||
|
||||
(void)Py_InitModule("timing", timing_methods);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue