mirror of https://github.com/python/cpython
[Bug #1542016] Report PCALL_POP value. This makes the return value of sys.callstats() match its docstring.
Backport candidate. Though it's an API change, this is a pretty obscure portion of the API.
This commit is contained in:
parent
935add1d30
commit
5f95870868
|
@ -14,6 +14,9 @@ Core and builtins
|
||||||
|
|
||||||
- Patch #1549049: Support long values in structmember.
|
- Patch #1549049: Support long values in structmember.
|
||||||
|
|
||||||
|
- Bug #1542016: make sys.callstats() match its docstring and return an
|
||||||
|
11-tuple (only relevant when Python is compiled with -DCALL_PROFILE).
|
||||||
|
|
||||||
- Bug #1545497: when given an explicit base, int() did ignore NULs
|
- Bug #1545497: when given an explicit base, int() did ignore NULs
|
||||||
embedded in the string to convert.
|
embedded in the string to convert.
|
||||||
|
|
||||||
|
|
|
@ -186,10 +186,10 @@ static int pcall[PCALL_NUM];
|
||||||
PyObject *
|
PyObject *
|
||||||
PyEval_GetCallStats(PyObject *self)
|
PyEval_GetCallStats(PyObject *self)
|
||||||
{
|
{
|
||||||
return Py_BuildValue("iiiiiiiiii",
|
return Py_BuildValue("iiiiiiiiiii",
|
||||||
pcall[0], pcall[1], pcall[2], pcall[3],
|
pcall[0], pcall[1], pcall[2], pcall[3],
|
||||||
pcall[4], pcall[5], pcall[6], pcall[7],
|
pcall[4], pcall[5], pcall[6], pcall[7],
|
||||||
pcall[8], pcall[9]);
|
pcall[8], pcall[9], pcall[10]);
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
#define PCALL(O)
|
#define PCALL(O)
|
||||||
|
|
Loading…
Reference in New Issue