Prepare collections module for pure python code entries.
This commit is contained in:
parent
3035d2397f
commit
eb9798892d
|
@ -0,0 +1,3 @@
|
|||
__all__ = ['deque', 'defaultdict']
|
||||
|
||||
from _collections import deque, defaultdict
|
|
@ -1337,11 +1337,11 @@ PyDoc_STRVAR(module_doc,
|
|||
");
|
||||
|
||||
PyMODINIT_FUNC
|
||||
initcollections(void)
|
||||
init_collections(void)
|
||||
{
|
||||
PyObject *m;
|
||||
|
||||
m = Py_InitModule3("collections", NULL, module_doc);
|
||||
m = Py_InitModule3("_collections", NULL, module_doc);
|
||||
if (m == NULL)
|
||||
return;
|
||||
|
|
@ -43,7 +43,7 @@ extern void initxxsubtype(void);
|
|||
extern void initzipimport(void);
|
||||
extern void init_random(void);
|
||||
extern void inititertools(void);
|
||||
extern void initcollections(void);
|
||||
extern void init_collections(void);
|
||||
extern void init_heapq(void);
|
||||
extern void init_bisect(void);
|
||||
extern void init_symtable(void);
|
||||
|
@ -124,7 +124,7 @@ struct _inittab _PyImport_Inittab[] = {
|
|||
{"_heapq", init_heapq},
|
||||
{"_lsprof", init_lsprof},
|
||||
{"itertools", inititertools},
|
||||
{"collections", initcollections},
|
||||
{"_collections", init_collections},
|
||||
{"_symtable", init_symtable},
|
||||
{"mmap", initmmap},
|
||||
{"_csv", init_csv},
|
||||
|
|
|
@ -458,7 +458,7 @@
|
|||
RelativePath="..\Objects\codeobject.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Modules\collectionsmodule.c">
|
||||
RelativePath="..\Modules\_collectionsmodule.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Python\compile.c">
|
||||
|
|
|
@ -1381,7 +1381,7 @@
|
|||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Modules\collectionsmodule.c"
|
||||
RelativePath="..\Modules\_collectionsmodule.c"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
|
|
2
setup.py
2
setup.py
|
@ -370,7 +370,7 @@ class PyBuildExt(build_ext):
|
|||
# fast iterator tools implemented in C
|
||||
exts.append( Extension("itertools", ["itertoolsmodule.c"]) )
|
||||
# high-performance collections
|
||||
exts.append( Extension("collections", ["collectionsmodule.c"]) )
|
||||
exts.append( Extension("_collections", ["_collectionsmodule.c"]) )
|
||||
# bisect
|
||||
exts.append( Extension("_bisect", ["_bisectmodule.c"]) )
|
||||
# heapq
|
||||
|
|
Loading…
Reference in New Issue