Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
847f3754
Commit
847f3754
authored
Feb 06, 2003
by
Michael W. Hudson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Correct lie about METH_NOARGS functions.
Backport candidate.
parent
90e05b0e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
Doc/api/newtypes.tex
Doc/api/newtypes.tex
+5
-5
No files found.
Doc/api/newtypes.tex
View file @
847f3754
...
...
@@ -244,7 +244,7 @@ binding flag.
\cfunction
{
Py
_
InitModule()
}
was used). The second parameter
(often called
\var
{
args
}
) is a tuple object representing all
arguments. This parameter is typically processed using
\cfunction
{
PyArg
_
ParseTuple()
}
.
\cfunction
{
PyArg
_
ParseTuple()
}
or
\cfunction
{
PyArg
_
UnpackTuple
}
.
\end{datadesc}
\begin{datadesc}
{
METH
_
KEYWORDS
}
...
...
@@ -259,10 +259,10 @@ binding flag.
\begin{datadesc}
{
METH
_
NOARGS
}
Methods without parameters don't need to check whether arguments are
given if they are listed with the
\constant
{
METH
_
NOARGS
}
flag. They
need to be of type
\ctype
{
Py
NoArgsFunction
}
: they expect a single
single
\ctype
{
PyObject*
}
as a parameter. When used with object
methods, this parameter is typically named
\code
{
self
}
and will hol
d
a reference to the object instance
.
need to be of type
\ctype
{
Py
CFunction
}
. When used with object
methods, the first parameter is typically named
\code
{
self
}
and will
hold a reference to the object instance. In all cases the secon
d
parameter will be
\NULL
.
\end{datadesc}
\begin{datadesc}
{
METH
_
O
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment