Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gevent
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gevent
Commits
5ce46ef5
Commit
5ce46ef5
authored
Jan 22, 2018
by
Jason Madden
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move the callback property to watcher.
parent
cdc1d6dd
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
14 deletions
+14
-14
src/gevent/libev/corecext.ppyx
src/gevent/libev/corecext.ppyx
+14
-14
No files found.
src/gevent/libev/corecext.ppyx
View file @
5ce46ef5
...
@@ -669,15 +669,6 @@ cdef public class callback [object PyGeventCallbackObject, type PyGeventCallback
...
@@ -669,15 +669,6 @@ cdef public class callback [object PyGeventCallbackObject, type PyGeventCallback
cdef libev.ev_##TYPE _watcher \
cdef libev.ev_##TYPE _watcher \
\
\
\
\
@property \
def callback(self): \
return self._callback \
\
@callback.setter \
def callback(self, object callback): \
if not PyCallable_Check(<PyObjectPtr>callback) and callback is not None: \
raise TypeError("Expected callable, not %r" % (callback, )) \
self._callback = callback \
\
\
def stop(self): \
def stop(self): \
_check_loop(self.loop) \
_check_loop(self.loop) \
...
@@ -784,6 +775,15 @@ cdef public class watcher [object PyGeventWatcherObject, type PyGeventWatcher_Ty
...
@@ -784,6 +775,15 @@ cdef public class watcher [object PyGeventWatcherObject, type PyGeventWatcher_Ty
libev.ev_unref(self.loop._ptr)
libev.ev_unref(self.loop._ptr)
self._flags |= 2
self._flags |= 2
@property
def callback(self):
return self._callback
@callback.setter
def callback(self, object callback):
if callback is not None and not callable(callback):
raise TypeError("Expected callable, not %r" % (callback, ))
self._callback = callback
def __repr__(self):
def __repr__(self):
if Py_ReprEnter(<PyObjectPtr>self) != 0:
if Py_ReprEnter(<PyObjectPtr>self) != 0:
...
...
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