Mercurial > cpython-lru_cache-weakref
comparison Python/sysmodule.c @ 70601:4af63c08f68a 2.7
sys.checkinterval() now refreshes the current countdown ticker.
| author | Raymond Hettinger <python@rcn.com> |
|---|---|
| date | Wed, 01 Jun 2011 18:21:42 -0700 |
| parents | 5cf8f6da8743 |
| children | c351536e804a |
comparison
equal
deleted
inserted
replaced
| 70598:bbaf419e7d0a | 70601:4af63c08f68a |
|---|---|
| 464 static PyObject * | 464 static PyObject * |
| 465 sys_setcheckinterval(PyObject *self, PyObject *args) | 465 sys_setcheckinterval(PyObject *self, PyObject *args) |
| 466 { | 466 { |
| 467 if (!PyArg_ParseTuple(args, "i:setcheckinterval", &_Py_CheckInterval)) | 467 if (!PyArg_ParseTuple(args, "i:setcheckinterval", &_Py_CheckInterval)) |
| 468 return NULL; | 468 return NULL; |
| 469 _Py_Ticker = _Py_CheckInterval; | |
| 469 Py_INCREF(Py_None); | 470 Py_INCREF(Py_None); |
| 470 return Py_None; | 471 return Py_None; |
| 471 } | 472 } |
| 472 | 473 |
| 473 PyDoc_STRVAR(setcheckinterval_doc, | 474 PyDoc_STRVAR(setcheckinterval_doc, |
