]> granicus.if.org Git - python/commit
Simplify and speedup uses of Py_BuildValue():
authorRaymond Hettinger <python@rcn.com>
Sun, 12 Oct 2003 19:09:37 +0000 (19:09 +0000)
committerRaymond Hettinger <python@rcn.com>
Sun, 12 Oct 2003 19:09:37 +0000 (19:09 +0000)
commit8ae468965700fd9900efc28bff8fa2015dae2bef
tree1f3545b2d2a3ad8b7d5692a7f84daa88d850b29c
parentcb2da43db8943e9e7b1d900bce1d6416339d6f64
Simplify and speedup uses of Py_BuildValue():

* Py_BuildValue("(OOO)",a,b,c)  -->  PyTuple_Pack(3,a,b,c)
* Py_BuildValue("()",a)         -->  PyTuple_New(0)
* Py_BuildValue("O", a)         -->  Py_INCREF(a)
25 files changed:
Modules/_sre.c
Modules/almodule.c
Modules/arraymodule.c
Modules/cPickle.c
Modules/cStringIO.c
Modules/datetimemodule.c
Modules/flmodule.c
Modules/mathmodule.c
Modules/posixmodule.c
Modules/pyexpat.c
Modules/regexmodule.c
Modules/selectmodule.c
Modules/socketmodule.c
Modules/svmodule.c
Modules/symtablemodule.c
Objects/classobject.c
Objects/complexobject.c
Objects/fileobject.c
Objects/typeobject.c
Python/bltinmodule.c
Python/ceval.c
Python/compile.c
Python/errors.c
Python/exceptions.c
Python/pythonrun.c