# [Python-checkins] CVS: python/dist/src/Doc/ext ext.tex,1.73,1.74

Fred Drake python-dev@python.org
Wed, 10 May 2000 16:33:22 -0400

Update of /projects/cvsroot/python/dist/src/Doc/ext
In directory seahag.cnri.reston.va.us:/home/fdrake/projects/python/Doc/ext

Modified Files:
ext.tex
Log Message:

Section "The Module's Method Table and Initialization Function":
Explain that the name of the initialization function must be
init<module>().  Omission noted by Daniel Kozan
<crum@dev-group.com>.

Index: ext.tex
===================================================================
RCS file: /projects/cvsroot/python/dist/src/Doc/ext/ext.tex,v
retrieving revision 1.73
retrieving revision 1.74
diff -C2 -r1.73 -r1.74
*** ext.tex	2000/05/03 15:17:02	1.73
--- ext.tex	2000/05/10 20:33:18	1.74
***************
*** 380,392 ****
function is provided below.

! The \constant{METH_KEYWORDS} bit may be set in the third field if keyword
! arguments should be passed to the function.  In this case, the C
! function should accept a third \samp{PyObject *} parameter which will
! be a dictionary of keywords.  Use \cfunction{PyArg_ParseTupleAndKeywords()}
! to parse the arguments to such a function.

The method table must be passed to the interpreter in the module's
! initialization function (which should be the only non-\code{static}
! item defined in the module file):

\begin{verbatim}
--- 380,395 ----
function is provided below.

! The \constant{METH_KEYWORDS} bit may be set in the third field if
! keyword arguments should be passed to the function.  In this case, the
! C function should accept a third \samp{PyObject *} parameter which
! will be a dictionary of keywords.  Use
! \cfunction{PyArg_ParseTupleAndKeywords()} to parse the arguments to
! such a function.

The method table must be passed to the interpreter in the module's
! initialization function.  The initialization function must be named
! \cfunction{init\var{name}()}, where \var{name} is the name of the
! module, and should be the only non-\keyword{static} item defined in
! the module file:

\begin{verbatim}