python.cfg: Add configurations for more functions (PyFloat_*, ...)

This commit is contained in:
versat 2020-03-11 10:10:33 +01:00
parent 900b99fbd8
commit 3b2e1cb367
1 changed files with 123 additions and 0 deletions

View File

@ -431,6 +431,58 @@
<strz/> <strz/>
</arg> </arg>
</function> </function>
<!-- double PyFloat_AsDouble(PyObject *pyfloat) -->
<function name="PyFloat_AsDouble">
<noreturn>false</noreturn>
<returnValue type="double"/>
<use-retval/>
<arg nr="1" direction="in">
<not-uninit/>
<not-bool/>
</arg>
</function>
<!-- double PyFloat_AS_DOUBLE(PyObject *pyfloat) -->
<function name="PyFloat_AS_DOUBLE">
<noreturn>false</noreturn>
<returnValue type="double"/>
<use-retval/>
<arg nr="1" direction="in">
<not-null/>
<not-uninit/>
<not-bool/>
</arg>
</function>
<!-- int PyFloat_Check(PyObject *p) -->
<!-- int PyFloat_CheckExact(PyObject *p) -->
<function name="PyFloat_Check,PyFloat_CheckExact">
<noreturn>false</noreturn>
<returnValue type="int"/>
<use-retval/>
<arg nr="1" direction="in">
<not-uninit/>
<not-bool/>
</arg>
</function>
<!-- PyObject* PyFloat_FromDouble(double v) -->
<function name="PyFloat_FromDouble">
<noreturn>false</noreturn>
<returnValue type="PyObject*"/>
<use-retval/>
<arg nr="1" direction="in">
<not-uninit/>
<not-bool/>
</arg>
</function>
<!-- PyObject* PyFloat_FromString(PyObject *str) -->
<function name="PyFloat_FromString">
<noreturn>false</noreturn>
<returnValue type="PyObject*"/>
<use-retval/>
<arg nr="1" direction="in">
<not-uninit/>
<not-bool/>
</arg>
</function>
<!-- int PyInt_Check(PyObject *o) --> <!-- int PyInt_Check(PyObject *o) -->
<function name="PyInt_Check"> <function name="PyInt_Check">
<returnValue type="int"/> <returnValue type="int"/>
@ -499,6 +551,62 @@
<valid>0:</valid> <valid>0:</valid>
</arg> </arg>
</function> </function>
<!-- int PyModule_AddIntConstant(PyObject *module, const char *name, long value) -->
<function name="PyModule_AddIntConstant">
<noreturn>false</noreturn>
<returnValue type="int"/>
<arg nr="1" direction="inout">
<not-uninit/>
</arg>
<arg nr="2" direction="in">
<not-null/>
<not-uninit/>
<strz/>
</arg>
<arg nr="3" direction="in">
<not-uninit/>
</arg>
</function>
<!-- int PyModule_AddObject(PyObject *module, const char *name, PyObject *value) -->
<!-- The hint "This means that its return value must be checked, and calling code must Py_DECREF()
value manually on error." in the documentation suggests to add use-retval. -->
<function name="PyModule_AddObject">
<noreturn>false</noreturn>
<returnValue type="int"/>
<use-retval/>
<arg nr="1">
<not-null/>
<not-uninit/>
</arg>
<arg nr="2" direction="in">
<not-null/>
<not-uninit/>
<strz/>
</arg>
<arg nr="3">
<not-null/>
<not-bool/>
</arg>
</function>
<!-- int PyModule_AddStringConstant(PyObject *module, const char *name, const char *value) -->
<function name="PyModule_AddStringConstant">
<noreturn>false</noreturn>
<returnValue type="int"/>
<arg nr="1" direction="inout">
<not-uninit/>
</arg>
<arg nr="2" direction="in">
<not-null/>
<not-uninit/>
<strz/>
</arg>
<arg nr="3" direction="in">
<not-null/>
<not-uninit/>
<strz/>
<not-bool/>
</arg>
</function>
<!-- void PyObject_Del(void *op) --> <!-- void PyObject_Del(void *op) -->
<function name="PyObject_Del"> <function name="PyObject_Del">
<noreturn>false</noreturn> <noreturn>false</noreturn>
@ -507,6 +615,21 @@
<not-uninit/> <not-uninit/>
</arg> </arg>
</function> </function>
<!-- PyObject* PyObject_GetAttrString(PyObject *o, const char *attr_name) -->
<function name="PyObject_GetAttrString">
<noreturn>false</noreturn>
<returnValue type="PyObject*"/>
<use-retval/>
<arg nr="1">
<not-uninit/>
</arg>
<arg nr="2" direction="in">
<not-null/>
<not-uninit/>
<strz/>
<not-bool/>
</arg>
</function>
<!-- PyAPI_FUNC(PyObject *) _PyObject_New(PyTypeObject *); --> <!-- PyAPI_FUNC(PyObject *) _PyObject_New(PyTypeObject *); -->
<function name="_PyObject_New"> <function name="_PyObject_New">
<noreturn>false</noreturn> <noreturn>false</noreturn>