Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
nexedi
cython
Commits
5430b81e
Commit
5430b81e
authored
May 23, 2015
by
Stefan Behnel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use correct metaclass when patching Coroutine into collections.abc module
parent
b9e0bdcf
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
7 deletions
+15
-7
Cython/Utility/Coroutine.c
Cython/Utility/Coroutine.c
+15
-7
No files found.
Cython/Utility/Coroutine.c
View file @
5430b81e
...
...
@@ -1215,14 +1215,18 @@ _module.Generator = mk_gen()
#ifdef __Pyx_Coroutine_USED
CSTRING
(
"""\
def mk_coroutine():
from abc import abstractmethod
from abc import abstractmethod
, ABCMeta
"""
)
#if PY_MAJOR_VERSION >= 3
" class Coroutine(metaclass=_module.ABCMeta):
\n
"
CSTRING
(
"""\
class Coroutine(metaclass=ABCMeta):
"""
)
#else
" class Coroutine(object):
\n
"
" __metaclass__ = _module.ABCMeta
\n
"
CSTRING
(
"""\
class Coroutine(object):
__metaclass__ = ABCMeta
"""
)
#endif
CSTRING
(
"""\
__slots__ = ()
...
...
@@ -1259,10 +1263,14 @@ def mk_coroutine():
"""
)
#if PY_MAJOR_VERSION >= 3
" class Awaitable(metaclass=_module.ABCMeta):
\n
"
CSTRING
(
"""\
class Awaitable(metaclass=ABCMeta):
"""
)
#else
" class Awaitable(object):
\n
"
" __metaclass__ = _module.ABCMeta
\n
"
CSTRING
(
"""\
class Awaitable(object):
__metaclass__ = ABCMeta
"""
)
#endif
CSTRING
(
"""\
__slots__ = ()
...
...
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