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
b3af1813
Commit
b3af1813
authored
Nov 08, 2003
by
Raymond Hettinger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Convert heapq.py to a C implementation.
parent
1021c44b
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
367 additions
and
1 deletion
+367
-1
Lib/test/test___all__.py
Lib/test/test___all__.py
+0
-1
Misc/NEWS
Misc/NEWS
+2
-0
Modules/heapqmodule.c
Modules/heapqmodule.c
+357
-0
PC/config.c
PC/config.c
+2
-0
PCbuild/pythoncore.dsp
PCbuild/pythoncore.dsp
+4
-0
setup.py
setup.py
+2
-0
No files found.
Lib/test/test___all__.py
View file @
b3af1813
...
...
@@ -100,7 +100,6 @@ class AllTest(unittest.TestCase):
self
.
check_all
(
"glob"
)
self
.
check_all
(
"gopherlib"
)
self
.
check_all
(
"gzip"
)
self
.
check_all
(
"heapq"
)
self
.
check_all
(
"htmllib"
)
self
.
check_all
(
"httplib"
)
self
.
check_all
(
"ihooks"
)
...
...
Misc/NEWS
View file @
b3af1813
...
...
@@ -104,6 +104,8 @@ Extension modules
Library
-------
-
heapq
.
py
has
been
converted
to
C
for
improved
performance
-
traceback
.
format_exc
has
been
added
(
similar
to
print_exc
but
it
returns
a
string
).
...
...
Lib/heapq.py
→
Modules/heapqmodule.c
View file @
b3af1813
This diff is collapsed.
Click to expand it.
PC/config.c
View file @
b3af1813
...
...
@@ -46,6 +46,7 @@ extern void initxxsubtype(void);
extern
void
initzipimport
(
void
);
extern
void
init_random
(
void
);
extern
void
inititertools
(
void
);
extern
void
initheapq
(
void
);
/* tools/freeze/makeconfig.py marker for additional "extern" */
/* -- ADDMODULE MARKER 1 -- */
...
...
@@ -98,6 +99,7 @@ struct _inittab _PyImport_Inittab[] = {
{
"_weakref"
,
init_weakref
},
{
"_hotshot"
,
init_hotshot
},
{
"_random"
,
init_random
},
{
"heapq"
,
initheapq
},
{
"itertools"
,
inititertools
},
{
"xxsubtype"
,
initxxsubtype
},
...
...
PCbuild/pythoncore.dsp
View file @
b3af1813
...
...
@@ -298,6 +298,10 @@ SOURCE=..\Parser\grammar1.c
# End Source File
# Begin Source File
SOURCE=..\Modules\heapqmodule.c
# End Source File
# Begin Source File
SOURCE=..\Modules\imageop.c
# End Source File
# Begin Source File
...
...
setup.py
View file @
b3af1813
...
...
@@ -322,6 +322,8 @@ class PyBuildExt(build_ext):
exts
.
append
(
Extension
(
"_random"
,
[
"_randommodule.c"
])
)
# fast iterator tools implemented in C
exts
.
append
(
Extension
(
"itertools"
,
[
"itertoolsmodule.c"
])
)
# heapq
exts
.
append
(
Extension
(
"heapq"
,
[
"heapqmodule.c"
])
)
# operator.add() and similar goodies
exts
.
append
(
Extension
(
'operator'
,
[
'operator.c'
])
)
# Python C API test module
...
...
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