mirror of
https://github.com/python/cpython.git
synced 2025-09-27 18:59:43 +00:00
asyncio doc: fix the sphinx extension for coroutine commands
This commit is contained in:
parent
4088ad9dce
commit
e170ed27c6
1 changed files with 0 additions and 5 deletions
|
@ -148,17 +148,12 @@ class PyDecoratorMethod(PyDecoratorMixin, PyClassmember):
|
||||||
class PyCoroutineMixin(object):
|
class PyCoroutineMixin(object):
|
||||||
def handle_signature(self, sig, signode):
|
def handle_signature(self, sig, signode):
|
||||||
ret = super(PyCoroutineMixin, self).handle_signature(sig, signode)
|
ret = super(PyCoroutineMixin, self).handle_signature(sig, signode)
|
||||||
# signode.insert(0, addnodes.desc_addname('coroutine ', 'coroutine '))
|
|
||||||
signode.insert(0, addnodes.desc_annotation('coroutine ', 'coroutine '))
|
signode.insert(0, addnodes.desc_annotation('coroutine ', 'coroutine '))
|
||||||
return ret
|
return ret
|
||||||
|
|
||||||
def needs_arglist(self):
|
|
||||||
return False
|
|
||||||
|
|
||||||
|
|
||||||
class PyCoroutineFunction(PyCoroutineMixin, PyModulelevel):
|
class PyCoroutineFunction(PyCoroutineMixin, PyModulelevel):
|
||||||
def run(self):
|
def run(self):
|
||||||
# a decorator function is a function after all
|
|
||||||
self.name = 'py:function'
|
self.name = 'py:function'
|
||||||
return PyModulelevel.run(self)
|
return PyModulelevel.run(self)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue