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
71e30a04
Commit
71e30a04
authored
Dec 24, 2008
by
Benjamin Peterson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
return the module object from PyMODINIT_FUNC
parent
80072cb7
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
6 additions
and
2 deletions
+6
-2
Doc/extending/extending.rst
Doc/extending/extending.rst
+2
-2
Doc/includes/noddy.c
Doc/includes/noddy.c
+1
-0
Doc/includes/noddy2.c
Doc/includes/noddy2.c
+1
-0
Doc/includes/noddy3.c
Doc/includes/noddy3.c
+1
-0
Doc/includes/noddy4.c
Doc/includes/noddy4.c
+1
-0
No files found.
Doc/extending/extending.rst
View file @
71e30a04
...
...
@@ -326,7 +326,7 @@ only non-\ ``static`` item defined in the module file::
return PyModule_Create(&spammodule);
}
Note that PyMODINIT_FUNC declares the function as ``
void
`` return type,
Note that PyMODINIT_FUNC declares the function as ``
PyObject *
`` return type,
declares any special linkage declarations required by the platform, and for C++
declares the function as ``extern "C"``.
...
...
Doc/includes/noddy.c
View file @
71e30a04
...
...
@@ -52,4 +52,5 @@ PyInit_noddy(void)
Py_INCREF
(
&
noddy_NoddyType
);
PyModule_AddObject
(
m
,
"Noddy"
,
(
PyObject
*
)
&
noddy_NoddyType
);
return
m
;
}
Doc/includes/noddy2.c
View file @
71e30a04
...
...
@@ -186,4 +186,5 @@ PyInit_noddy2(void)
Py_INCREF
(
&
NoddyType
);
PyModule_AddObject
(
m
,
"Noddy"
,
(
PyObject
*
)
&
NoddyType
);
return
m
;
}
Doc/includes/noddy3.c
View file @
71e30a04
...
...
@@ -239,4 +239,5 @@ PyInit_noddy3(void)
Py_INCREF
(
&
NoddyType
);
PyModule_AddObject
(
m
,
"Noddy"
,
(
PyObject
*
)
&
NoddyType
);
return
m
;
}
Doc/includes/noddy4.c
View file @
71e30a04
...
...
@@ -221,4 +221,5 @@ PyInit_noddy4(void)
Py_INCREF
(
&
NoddyType
);
PyModule_AddObject
(
m
,
"Noddy"
,
(
PyObject
*
)
&
NoddyType
);
return
m
;
}
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