mirror of https://github.com/python/cpython
Document PyObject_AsFileDescriptor
This commit is contained in:
parent
06051edc0d
commit
8c46b30e0a
|
@ -1419,6 +1419,13 @@ failure. This is the equivalent of the Python statement \samp{del
|
||||||
\var{o}[\var{key}]}.
|
\var{o}[\var{key}]}.
|
||||||
\end{cfuncdesc}
|
\end{cfuncdesc}
|
||||||
|
|
||||||
|
\begin{cfuncdesc}{int}{PyObject_AsFileDescriptor}{PyObject *o}
|
||||||
|
Derives a file-descriptor from a Python object. If the object
|
||||||
|
is an integer or long integer, its value is returned. If not, the
|
||||||
|
object's \method{fileno()} method is called if it exists; the method
|
||||||
|
must return an integer or long integer, which is returned as the file
|
||||||
|
descriptor value. Returns \code{-1} on failure.
|
||||||
|
\end{cfuncdesc}
|
||||||
|
|
||||||
\section{Number Protocol \label{number}}
|
\section{Number Protocol \label{number}}
|
||||||
|
|
||||||
|
|
|
@ -539,6 +539,9 @@ PyNumber_Xor:PyObject*:o2:0:
|
||||||
PyOS_GetLastModificationTime:long:::
|
PyOS_GetLastModificationTime:long:::
|
||||||
PyOS_GetLastModificationTime:char*:filename::
|
PyOS_GetLastModificationTime:char*:filename::
|
||||||
|
|
||||||
|
PyObject_AsFileDescriptor:int:::
|
||||||
|
PyObject_AsFileDescriptor:PyObject*:o:0:
|
||||||
|
|
||||||
PyObject_CallFunction:PyObject*::+1:
|
PyObject_CallFunction:PyObject*::+1:
|
||||||
PyObject_CallFunction:PyObject*:callable_object:0:
|
PyObject_CallFunction:PyObject*:callable_object:0:
|
||||||
PyObject_CallFunction:char*:format::
|
PyObject_CallFunction:char*:format::
|
||||||
|
|
Loading…
Reference in New Issue