summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew M. Kuchling <amk@amk.ca>2000-07-13 23:58:16 (GMT)
committerAndrew M. Kuchling <amk@amk.ca>2000-07-13 23:58:16 (GMT)
commit8c46b30e0a9dc91b56cec1d1204069c47a64f217 (patch)
treefadb2109f39fea60f754e23bdcfa66c2a8896c9f
parent06051edc0d4987994ccd9d578210a1fe1fa1d13a (diff)
downloadcpython-8c46b30e0a9dc91b56cec1d1204069c47a64f217.zip
cpython-8c46b30e0a9dc91b56cec1d1204069c47a64f217.tar.gz
cpython-8c46b30e0a9dc91b56cec1d1204069c47a64f217.tar.bz2
Document PyObject_AsFileDescriptor
-rw-r--r--Doc/api/api.tex7
-rw-r--r--Doc/api/refcounts.dat3
2 files changed, 10 insertions, 0 deletions
diff --git a/Doc/api/api.tex b/Doc/api/api.tex
index 31ba95e..367cb06 100644
--- a/Doc/api/api.tex
+++ b/Doc/api/api.tex
@@ -1419,6 +1419,13 @@ failure. This is the equivalent of the Python statement \samp{del
\var{o}[\var{key}]}.
\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}}
diff --git a/Doc/api/refcounts.dat b/Doc/api/refcounts.dat
index be46518..c31d3b3 100644
--- a/Doc/api/refcounts.dat
+++ b/Doc/api/refcounts.dat
@@ -539,6 +539,9 @@ PyNumber_Xor:PyObject*:o2:0:
PyOS_GetLastModificationTime:long:::
PyOS_GetLastModificationTime:char*:filename::
+PyObject_AsFileDescriptor:int:::
+PyObject_AsFileDescriptor:PyObject*:o:0:
+
PyObject_CallFunction:PyObject*::+1:
PyObject_CallFunction:PyObject*:callable_object:0:
PyObject_CallFunction:char*:format::