Mercurial > cpython-lru_cache-weakref
diff Python/pythonrun.c @ 31797:846b3ee7e106 legacy-trunk
Changed random calls to PyThreadState_Get() to use the macro
| author | Nicholas Bastin <nick.bastin@gmail.com> |
|---|---|
| date | Wed, 24 Mar 2004 22:22:12 +0000 |
| parents | 76053a1dd452 |
| children | 78bd25b42d46 |
line wrap: on
line diff
--- a/Python/pythonrun.c Wed Mar 24 21:57:10 2004 +0000 +++ b/Python/pythonrun.c Wed Mar 24 22:22:12 2004 +0000 @@ -316,7 +316,7 @@ initialized = 0; /* Get current thread state and interpreter pointer */ - tstate = PyThreadState_Get(); + tstate = PyThreadState_GET(); interp = tstate->interp; /* Disable signal handling */ @@ -529,7 +529,7 @@ { PyInterpreterState *interp = tstate->interp; - if (tstate != PyThreadState_Get()) + if (tstate != PyThreadState_GET()) Py_FatalError("Py_EndInterpreter: thread is not current"); if (tstate->frame != NULL) Py_FatalError("Py_EndInterpreter: thread still has a frame"); @@ -1461,7 +1461,7 @@ msg = "too many levels of indentation"; break; case E_DECODE: { /* XXX */ - PyThreadState* tstate = PyThreadState_Get(); + PyThreadState* tstate = PyThreadState_GET(); PyObject* value = tstate->curexc_value; if (value != NULL) { u = PyObject_Repr(value);
