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
7240d254
Commit
7240d254
authored
Oct 24, 2016
by
Raymond Hettinger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue #5830: Remove old comment. Add empty slots.
parent
51d55283
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
5 deletions
+1
-5
Lib/sched.py
Lib/sched.py
+1
-5
No files found.
Lib/sched.py
View file @
7240d254
...
@@ -23,11 +23,6 @@ The action function may be an instance method so it
...
@@ -23,11 +23,6 @@ The action function may be an instance method so it
has another way to reference private data (besides global variables).
has another way to reference private data (besides global variables).
"""
"""
# XXX The timefunc and delayfunc should have been defined as methods
# XXX so you can define new kinds of schedulers using subclassing
# XXX instead of having to define a module or class just to hold
# XXX the global state of your particular time and delay functions.
import
time
import
time
import
heapq
import
heapq
from
collections
import
namedtuple
from
collections
import
namedtuple
...
@@ -40,6 +35,7 @@ from time import monotonic as _time
...
@@ -40,6 +35,7 @@ from time import monotonic as _time
__all__
=
[
"scheduler"
]
__all__
=
[
"scheduler"
]
class
Event
(
namedtuple
(
'Event'
,
'time, priority, action, argument, kwargs'
)):
class
Event
(
namedtuple
(
'Event'
,
'time, priority, action, argument, kwargs'
)):
__slots__
=
[]
def
__eq__
(
s
,
o
):
return
(
s
.
time
,
s
.
priority
)
==
(
o
.
time
,
o
.
priority
)
def
__eq__
(
s
,
o
):
return
(
s
.
time
,
s
.
priority
)
==
(
o
.
time
,
o
.
priority
)
def
__lt__
(
s
,
o
):
return
(
s
.
time
,
s
.
priority
)
<
(
o
.
time
,
o
.
priority
)
def
__lt__
(
s
,
o
):
return
(
s
.
time
,
s
.
priority
)
<
(
o
.
time
,
o
.
priority
)
def
__le__
(
s
,
o
):
return
(
s
.
time
,
s
.
priority
)
<=
(
o
.
time
,
o
.
priority
)
def
__le__
(
s
,
o
):
return
(
s
.
time
,
s
.
priority
)
<=
(
o
.
time
,
o
.
priority
)
...
...
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