Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
bca4939d
Kaydet (Commit)
bca4939d
authored
Eyl 03, 2017
tarafından
Serhiy Storchaka
Kaydeden (comit)
GitHub
Eyl 03, 2017
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
bpo-31185: Fixed miscellaneous errors in asyncio speedup module. (#3076)
üst
8df44ee8
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
232 additions
and
203 deletions
+232
-203
test_futures.py
Lib/test/test_asyncio/test_futures.py
+37
-8
2017-08-11-19-30-00.bpo-31185.i6TPgL.rst
...S.d/next/Library/2017-08-11-19-30-00.bpo-31185.i6TPgL.rst
+1
-0
_asynciomodule.c
Modules/_asynciomodule.c
+190
-191
_asynciomodule.c.h
Modules/clinic/_asynciomodule.c.h
+4
-4
No files found.
Lib/test/test_asyncio/test_futures.py
Dosyayı görüntüle @
bca4939d
...
@@ -100,8 +100,8 @@ class DuckTests(test_utils.TestCase):
...
@@ -100,8 +100,8 @@ class DuckTests(test_utils.TestCase):
class
BaseFutureTests
:
class
BaseFutureTests
:
def
_new_future
(
self
,
loop
=
None
):
def
_new_future
(
self
,
*
args
,
**
kwargs
):
r
aise
NotImplementedError
r
eturn
self
.
cls
(
*
args
,
**
kwargs
)
def
setUp
(
self
):
def
setUp
(
self
):
super
()
.
setUp
()
super
()
.
setUp
()
...
@@ -147,6 +147,39 @@ class BaseFutureTests:
...
@@ -147,6 +147,39 @@ class BaseFutureTests:
# Make sure Future doesn't accept a positional argument
# Make sure Future doesn't accept a positional argument
self
.
assertRaises
(
TypeError
,
self
.
_new_future
,
42
)
self
.
assertRaises
(
TypeError
,
self
.
_new_future
,
42
)
def
test_uninitialized
(
self
):
fut
=
self
.
cls
.
__new__
(
self
.
cls
,
loop
=
self
.
loop
)
self
.
assertRaises
(
asyncio
.
InvalidStateError
,
fut
.
result
)
fut
=
self
.
cls
.
__new__
(
self
.
cls
,
loop
=
self
.
loop
)
self
.
assertRaises
(
asyncio
.
InvalidStateError
,
fut
.
exception
)
fut
=
self
.
cls
.
__new__
(
self
.
cls
,
loop
=
self
.
loop
)
with
self
.
assertRaises
((
RuntimeError
,
AttributeError
)):
fut
.
set_result
(
None
)
fut
=
self
.
cls
.
__new__
(
self
.
cls
,
loop
=
self
.
loop
)
with
self
.
assertRaises
((
RuntimeError
,
AttributeError
)):
fut
.
set_exception
(
Exception
)
fut
=
self
.
cls
.
__new__
(
self
.
cls
,
loop
=
self
.
loop
)
with
self
.
assertRaises
((
RuntimeError
,
AttributeError
)):
fut
.
cancel
()
fut
=
self
.
cls
.
__new__
(
self
.
cls
,
loop
=
self
.
loop
)
with
self
.
assertRaises
((
RuntimeError
,
AttributeError
)):
fut
.
add_done_callback
(
lambda
f
:
None
)
fut
=
self
.
cls
.
__new__
(
self
.
cls
,
loop
=
self
.
loop
)
with
self
.
assertRaises
((
RuntimeError
,
AttributeError
)):
fut
.
remove_done_callback
(
lambda
f
:
None
)
fut
=
self
.
cls
.
__new__
(
self
.
cls
,
loop
=
self
.
loop
)
with
self
.
assertRaises
((
RuntimeError
,
AttributeError
)):
fut
.
_schedule_callbacks
()
fut
=
self
.
cls
.
__new__
(
self
.
cls
,
loop
=
self
.
loop
)
try
:
repr
(
fut
)
except
AttributeError
:
pass
fut
=
self
.
cls
.
__new__
(
self
.
cls
,
loop
=
self
.
loop
)
fut
.
cancelled
()
fut
.
done
()
iter
(
fut
)
def
test_cancel
(
self
):
def
test_cancel
(
self
):
f
=
self
.
_new_future
(
loop
=
self
.
loop
)
f
=
self
.
_new_future
(
loop
=
self
.
loop
)
self
.
assertTrue
(
f
.
cancel
())
self
.
assertTrue
(
f
.
cancel
())
...
@@ -501,15 +534,11 @@ class BaseFutureTests:
...
@@ -501,15 +534,11 @@ class BaseFutureTests:
@unittest.skipUnless
(
hasattr
(
futures
,
'_CFuture'
),
@unittest.skipUnless
(
hasattr
(
futures
,
'_CFuture'
),
'requires the C _asyncio module'
)
'requires the C _asyncio module'
)
class
CFutureTests
(
BaseFutureTests
,
test_utils
.
TestCase
):
class
CFutureTests
(
BaseFutureTests
,
test_utils
.
TestCase
):
cls
=
getattr
(
futures
,
'_CFuture'
)
def
_new_future
(
self
,
*
args
,
**
kwargs
):
return
futures
.
_CFuture
(
*
args
,
**
kwargs
)
class
PyFutureTests
(
BaseFutureTests
,
test_utils
.
TestCase
):
class
PyFutureTests
(
BaseFutureTests
,
test_utils
.
TestCase
):
cls
=
futures
.
_PyFuture
def
_new_future
(
self
,
*
args
,
**
kwargs
):
return
futures
.
_PyFuture
(
*
args
,
**
kwargs
)
class
BaseFutureDoneCallbackTests
():
class
BaseFutureDoneCallbackTests
():
...
...
Misc/NEWS.d/next/Library/2017-08-11-19-30-00.bpo-31185.i6TPgL.rst
0 → 100644
Dosyayı görüntüle @
bca4939d
Fixed miscellaneous errors in asyncio speedup module.
Modules/_asynciomodule.c
Dosyayı görüntüle @
bca4939d
...
@@ -68,7 +68,7 @@ typedef struct {
...
@@ -68,7 +68,7 @@ typedef struct {
PyObject_HEAD
PyObject_HEAD
TaskObj
*
sw_task
;
TaskObj
*
sw_task
;
PyObject
*
sw_arg
;
PyObject
*
sw_arg
;
}
TaskS
end
MethWrapper
;
}
TaskS
tep
MethWrapper
;
typedef
struct
{
typedef
struct
{
PyObject_HEAD
PyObject_HEAD
...
@@ -92,11 +92,11 @@ static int
...
@@ -92,11 +92,11 @@ static int
future_schedule_callbacks
(
FutureObj
*
fut
)
future_schedule_callbacks
(
FutureObj
*
fut
)
{
{
Py_ssize_t
len
;
Py_ssize_t
len
;
PyObject
*
iter
s
;
PyObject
*
callback
s
;
int
i
;
int
i
;
if
(
fut
->
fut_callbacks
==
NULL
)
{
if
(
fut
->
fut_callbacks
==
NULL
)
{
PyErr_SetString
(
PyExc_RuntimeError
,
"
NULL callbacks
"
);
PyErr_SetString
(
PyExc_RuntimeError
,
"
uninitialized Future object
"
);
return
-
1
;
return
-
1
;
}
}
...
@@ -105,42 +105,41 @@ future_schedule_callbacks(FutureObj *fut)
...
@@ -105,42 +105,41 @@ future_schedule_callbacks(FutureObj *fut)
return
0
;
return
0
;
}
}
iter
s
=
PyList_GetSlice
(
fut
->
fut_callbacks
,
0
,
len
);
callback
s
=
PyList_GetSlice
(
fut
->
fut_callbacks
,
0
,
len
);
if
(
iter
s
==
NULL
)
{
if
(
callback
s
==
NULL
)
{
return
-
1
;
return
-
1
;
}
}
if
(
PyList_SetSlice
(
fut
->
fut_callbacks
,
0
,
len
,
NULL
)
<
0
)
{
if
(
PyList_SetSlice
(
fut
->
fut_callbacks
,
0
,
len
,
NULL
)
<
0
)
{
Py_DECREF
(
iter
s
);
Py_DECREF
(
callback
s
);
return
-
1
;
return
-
1
;
}
}
for
(
i
=
0
;
i
<
len
;
i
++
)
{
for
(
i
=
0
;
i
<
len
;
i
++
)
{
PyObject
*
handle
=
NULL
;
PyObject
*
handle
;
PyObject
*
cb
=
PyList_GET_ITEM
(
iter
s
,
i
);
PyObject
*
cb
=
PyList_GET_ITEM
(
callback
s
,
i
);
handle
=
_PyObject_CallMethodIdObjArgs
(
fut
->
fut_loop
,
&
PyId_call_soon
,
handle
=
_PyObject_CallMethodIdObjArgs
(
fut
->
fut_loop
,
&
PyId_call_soon
,
cb
,
fut
,
NULL
);
cb
,
fut
,
NULL
);
if
(
handle
==
NULL
)
{
if
(
handle
==
NULL
)
{
Py_DECREF
(
iter
s
);
Py_DECREF
(
callback
s
);
return
-
1
;
return
-
1
;
}
}
else
{
Py_DECREF
(
handle
);
Py_DECREF
(
handle
);
}
}
}
Py_DECREF
(
iter
s
);
Py_DECREF
(
callback
s
);
return
0
;
return
0
;
}
}
static
int
static
int
future_init
(
FutureObj
*
fut
,
PyObject
*
loop
)
future_init
(
FutureObj
*
fut
,
PyObject
*
loop
)
{
{
PyObject
*
res
=
NULL
;
PyObject
*
res
;
int
is_true
;
_Py_IDENTIFIER
(
get_debug
);
_Py_IDENTIFIER
(
get_debug
);
if
(
loop
==
NULL
||
loop
==
Py_None
)
{
if
(
loop
==
Py_None
)
{
loop
=
_PyObject_CallNoArg
(
asyncio_get_event_loop
);
loop
=
_PyObject_CallNoArg
(
asyncio_get_event_loop
);
if
(
loop
==
NULL
)
{
if
(
loop
==
NULL
)
{
return
-
1
;
return
-
1
;
...
@@ -149,25 +148,25 @@ future_init(FutureObj *fut, PyObject *loop)
...
@@ -149,25 +148,25 @@ future_init(FutureObj *fut, PyObject *loop)
else
{
else
{
Py_INCREF
(
loop
);
Py_INCREF
(
loop
);
}
}
Py_CLEAR
(
fut
->
fut_loop
);
Py_XSETREF
(
fut
->
fut_loop
,
loop
);
fut
->
fut_loop
=
loop
;
res
=
_PyObject_CallMethodId
(
fut
->
fut_loop
,
&
PyId_get_debug
,
NULL
);
res
=
_PyObject_CallMethodId
(
fut
->
fut_loop
,
&
PyId_get_debug
,
NULL
);
if
(
res
==
NULL
)
{
if
(
res
==
NULL
)
{
return
-
1
;
return
-
1
;
}
}
if
(
PyObject_IsTrue
(
res
))
{
is_true
=
PyObject_IsTrue
(
res
);
Py_CLEAR
(
res
);
Py_DECREF
(
res
);
fut
->
fut_source_tb
=
_PyObject_CallNoArg
(
traceback_extract_stack
);
if
(
is_true
<
0
)
{
if
(
fut
->
fut_source_tb
==
NULL
)
{
return
-
1
;
return
-
1
;
}
}
if
(
is_true
)
{
Py_XSETREF
(
fut
->
fut_source_tb
,
_PyObject_CallNoArg
(
traceback_extract_stack
));
if
(
fut
->
fut_source_tb
==
NULL
)
{
return
-
1
;
}
}
else
{
Py_CLEAR
(
res
);
}
}
fut
->
fut_callbacks
=
PyList_New
(
0
);
Py_XSETREF
(
fut
->
fut_callbacks
,
PyList_New
(
0
)
);
if
(
fut
->
fut_callbacks
==
NULL
)
{
if
(
fut
->
fut_callbacks
==
NULL
)
{
return
-
1
;
return
-
1
;
}
}
...
@@ -183,6 +182,7 @@ future_set_result(FutureObj *fut, PyObject *res)
...
@@ -183,6 +182,7 @@ future_set_result(FutureObj *fut, PyObject *res)
return
NULL
;
return
NULL
;
}
}
assert
(
!
fut
->
fut_result
);
Py_INCREF
(
res
);
Py_INCREF
(
res
);
fut
->
fut_result
=
res
;
fut
->
fut_result
=
res
;
fut
->
fut_state
=
STATE_FINISHED
;
fut
->
fut_state
=
STATE_FINISHED
;
...
@@ -208,6 +208,11 @@ future_set_exception(FutureObj *fut, PyObject *exc)
...
@@ -208,6 +208,11 @@ future_set_exception(FutureObj *fut, PyObject *exc)
if
(
exc_val
==
NULL
)
{
if
(
exc_val
==
NULL
)
{
return
NULL
;
return
NULL
;
}
}
if
(
fut
->
fut_state
!=
STATE_PENDING
)
{
Py_DECREF
(
exc_val
);
PyErr_SetString
(
asyncio_InvalidStateError
,
"invalid state"
);
return
NULL
;
}
}
}
else
{
else
{
exc_val
=
exc
;
exc_val
=
exc
;
...
@@ -226,6 +231,7 @@ future_set_exception(FutureObj *fut, PyObject *exc)
...
@@ -226,6 +231,7 @@ future_set_exception(FutureObj *fut, PyObject *exc)
return
NULL
;
return
NULL
;
}
}
assert
(
!
fut
->
fut_exception
);
fut
->
fut_exception
=
exc_val
;
fut
->
fut_exception
=
exc_val
;
fut
->
fut_state
=
STATE_FINISHED
;
fut
->
fut_state
=
STATE_FINISHED
;
...
@@ -240,33 +246,16 @@ future_set_exception(FutureObj *fut, PyObject *exc)
...
@@ -240,33 +246,16 @@ future_set_exception(FutureObj *fut, PyObject *exc)
static
int
static
int
future_get_result
(
FutureObj
*
fut
,
PyObject
**
result
)
future_get_result
(
FutureObj
*
fut
,
PyObject
**
result
)
{
{
PyObject
*
exc
;
if
(
fut
->
fut_state
==
STATE_CANCELLED
)
{
if
(
fut
->
fut_state
==
STATE_CANCELLED
)
{
exc
=
_PyObject_CallNoArg
(
asyncio_CancelledError
);
PyErr_SetNone
(
asyncio_CancelledError
);
if
(
exc
==
NULL
)
{
return
-
1
;
return
-
1
;
}
}
*
result
=
exc
;
return
1
;
}
if
(
fut
->
fut_state
!=
STATE_FINISHED
)
{
if
(
fut
->
fut_state
!=
STATE_FINISHED
)
{
PyObject
*
msg
=
PyUnicode_FromString
(
"Result is not ready."
);
PyErr_SetString
(
asyncio_InvalidStateError
,
"Result is not set."
);
if
(
msg
==
NULL
)
{
return
-
1
;
return
-
1
;
}
}
exc
=
PyObject_CallFunctionObjArgs
(
asyncio_InvalidStateError
,
msg
,
NULL
);
Py_DECREF
(
msg
);
if
(
exc
==
NULL
)
{
return
-
1
;
}
*
result
=
exc
;
return
1
;
}
fut
->
fut_log_tb
=
0
;
fut
->
fut_log_tb
=
0
;
if
(
fut
->
fut_exception
!=
NULL
)
{
if
(
fut
->
fut_exception
!=
NULL
)
{
Py_INCREF
(
fut
->
fut_exception
);
Py_INCREF
(
fut
->
fut_exception
);
...
@@ -286,15 +275,16 @@ future_add_done_callback(FutureObj *fut, PyObject *arg)
...
@@ -286,15 +275,16 @@ future_add_done_callback(FutureObj *fut, PyObject *arg)
PyObject
*
handle
=
_PyObject_CallMethodIdObjArgs
(
fut
->
fut_loop
,
PyObject
*
handle
=
_PyObject_CallMethodIdObjArgs
(
fut
->
fut_loop
,
&
PyId_call_soon
,
&
PyId_call_soon
,
arg
,
fut
,
NULL
);
arg
,
fut
,
NULL
);
if
(
handle
==
NULL
)
{
if
(
handle
==
NULL
)
{
return
NULL
;
return
NULL
;
}
}
else
{
Py_DECREF
(
handle
);
Py_DECREF
(
handle
);
}
}
}
else
{
else
{
if
(
fut
->
fut_callbacks
==
NULL
)
{
PyErr_SetString
(
PyExc_RuntimeError
,
"uninitialized Future object"
);
return
NULL
;
}
int
err
=
PyList_Append
(
fut
->
fut_callbacks
,
arg
);
int
err
=
PyList_Append
(
fut
->
fut_callbacks
,
arg
);
if
(
err
!=
0
)
{
if
(
err
!=
0
)
{
return
NULL
;
return
NULL
;
...
@@ -324,7 +314,7 @@ future_cancel(FutureObj *fut)
...
@@ -324,7 +314,7 @@ future_cancel(FutureObj *fut)
_asyncio.Future.__init__
_asyncio.Future.__init__
*
*
loop:
'O' = NULL
loop:
object = None
This class is *almost* compatible with concurrent.futures.Future.
This class is *almost* compatible with concurrent.futures.Future.
...
@@ -342,7 +332,7 @@ This class is *almost* compatible with concurrent.futures.Future.
...
@@ -342,7 +332,7 @@ This class is *almost* compatible with concurrent.futures.Future.
static
int
static
int
_asyncio_Future___init___impl
(
FutureObj
*
self
,
PyObject
*
loop
)
_asyncio_Future___init___impl
(
FutureObj
*
self
,
PyObject
*
loop
)
/*[clinic end generated code: output=9ed75799eaccb5d6 input=8
e1681f23605be2d
]*/
/*[clinic end generated code: output=9ed75799eaccb5d6 input=8
9af317082bc0bf8
]*/
{
{
return
future_init
(
self
,
loop
);
return
future_init
(
self
,
loop
);
...
@@ -420,12 +410,12 @@ _asyncio_Future_exception_impl(FutureObj *self)
...
@@ -420,12 +410,12 @@ _asyncio_Future_exception_impl(FutureObj *self)
/*[clinic end generated code: output=88b20d4f855e0710 input=733547a70c841c68]*/
/*[clinic end generated code: output=88b20d4f855e0710 input=733547a70c841c68]*/
{
{
if
(
self
->
fut_state
==
STATE_CANCELLED
)
{
if
(
self
->
fut_state
==
STATE_CANCELLED
)
{
PyErr_Set
String
(
asyncio_CancelledError
,
""
);
PyErr_Set
None
(
asyncio_CancelledError
);
return
NULL
;
return
NULL
;
}
}
if
(
self
->
fut_state
!=
STATE_FINISHED
)
{
if
(
self
->
fut_state
!=
STATE_FINISHED
)
{
PyErr_SetString
(
asyncio_InvalidStateError
,
"
Result is not ready
."
);
PyErr_SetString
(
asyncio_InvalidStateError
,
"
Exception is not set
."
);
return
NULL
;
return
NULL
;
}
}
...
@@ -441,7 +431,7 @@ _asyncio_Future_exception_impl(FutureObj *self)
...
@@ -441,7 +431,7 @@ _asyncio_Future_exception_impl(FutureObj *self)
/*[clinic input]
/*[clinic input]
_asyncio.Future.set_result
_asyncio.Future.set_result
res:
'O'
res:
object
/
/
Mark the future done and set its result.
Mark the future done and set its result.
...
@@ -452,7 +442,7 @@ InvalidStateError.
...
@@ -452,7 +442,7 @@ InvalidStateError.
static
PyObject
*
static
PyObject
*
_asyncio_Future_set_result
(
FutureObj
*
self
,
PyObject
*
res
)
_asyncio_Future_set_result
(
FutureObj
*
self
,
PyObject
*
res
)
/*[clinic end generated code: output=a620abfc2796bfb6 input=
8619565e0503357e
]*/
/*[clinic end generated code: output=a620abfc2796bfb6 input=
5b9dc180f1baa56d
]*/
{
{
return
future_set_result
(
self
,
res
);
return
future_set_result
(
self
,
res
);
}
}
...
@@ -460,7 +450,7 @@ _asyncio_Future_set_result(FutureObj *self, PyObject *res)
...
@@ -460,7 +450,7 @@ _asyncio_Future_set_result(FutureObj *self, PyObject *res)
/*[clinic input]
/*[clinic input]
_asyncio.Future.set_exception
_asyncio.Future.set_exception
exception:
'O'
exception:
object
/
/
Mark the future done and set an exception.
Mark the future done and set an exception.
...
@@ -471,7 +461,7 @@ InvalidStateError.
...
@@ -471,7 +461,7 @@ InvalidStateError.
static
PyObject
*
static
PyObject
*
_asyncio_Future_set_exception
(
FutureObj
*
self
,
PyObject
*
exception
)
_asyncio_Future_set_exception
(
FutureObj
*
self
,
PyObject
*
exception
)
/*[clinic end generated code: output=f1c1b0cd321be360 input=
1377dbe15e6ea186
]*/
/*[clinic end generated code: output=f1c1b0cd321be360 input=
e45b7d7aa71cc66d
]*/
{
{
return
future_set_exception
(
self
,
exception
);
return
future_set_exception
(
self
,
exception
);
}
}
...
@@ -479,7 +469,7 @@ _asyncio_Future_set_exception(FutureObj *self, PyObject *exception)
...
@@ -479,7 +469,7 @@ _asyncio_Future_set_exception(FutureObj *self, PyObject *exception)
/*[clinic input]
/*[clinic input]
_asyncio.Future.add_done_callback
_asyncio.Future.add_done_callback
fn:
'O'
fn:
object
/
/
Add a callback to be run when the future becomes done.
Add a callback to be run when the future becomes done.
...
@@ -491,7 +481,7 @@ scheduled with call_soon.
...
@@ -491,7 +481,7 @@ scheduled with call_soon.
static
PyObject
*
static
PyObject
*
_asyncio_Future_add_done_callback
(
FutureObj
*
self
,
PyObject
*
fn
)
_asyncio_Future_add_done_callback
(
FutureObj
*
self
,
PyObject
*
fn
)
/*[clinic end generated code: output=819e09629b2ec2b5 input=8
cce187e32cec6a8
]*/
/*[clinic end generated code: output=819e09629b2ec2b5 input=8
f818b39990b027d
]*/
{
{
return
future_add_done_callback
(
self
,
fn
);
return
future_add_done_callback
(
self
,
fn
);
}
}
...
@@ -499,7 +489,7 @@ _asyncio_Future_add_done_callback(FutureObj *self, PyObject *fn)
...
@@ -499,7 +489,7 @@ _asyncio_Future_add_done_callback(FutureObj *self, PyObject *fn)
/*[clinic input]
/*[clinic input]
_asyncio.Future.remove_done_callback
_asyncio.Future.remove_done_callback
fn:
'O'
fn:
object
/
/
Remove all instances of a callback from the "call when done" list.
Remove all instances of a callback from the "call when done" list.
...
@@ -509,11 +499,16 @@ Returns the number of callbacks removed.
...
@@ -509,11 +499,16 @@ Returns the number of callbacks removed.
static
PyObject
*
static
PyObject
*
_asyncio_Future_remove_done_callback
(
FutureObj
*
self
,
PyObject
*
fn
)
_asyncio_Future_remove_done_callback
(
FutureObj
*
self
,
PyObject
*
fn
)
/*[clinic end generated code: output=5ab1fb52b24ef31f input=
3fedb73e1409c31c
]*/
/*[clinic end generated code: output=5ab1fb52b24ef31f input=
0a43280a149d505b
]*/
{
{
PyObject
*
newlist
;
PyObject
*
newlist
;
Py_ssize_t
len
,
i
,
j
=
0
;
Py_ssize_t
len
,
i
,
j
=
0
;
if
(
self
->
fut_callbacks
==
NULL
)
{
PyErr_SetString
(
PyExc_RuntimeError
,
"uninitialized Future object"
);
return
NULL
;
}
len
=
PyList_GET_SIZE
(
self
->
fut_callbacks
);
len
=
PyList_GET_SIZE
(
self
->
fut_callbacks
);
if
(
len
==
0
)
{
if
(
len
==
0
)
{
return
PyLong_FromSsize_t
(
0
);
return
PyLong_FromSsize_t
(
0
);
...
@@ -527,30 +522,32 @@ _asyncio_Future_remove_done_callback(FutureObj *self, PyObject *fn)
...
@@ -527,30 +522,32 @@ _asyncio_Future_remove_done_callback(FutureObj *self, PyObject *fn)
for
(
i
=
0
;
i
<
PyList_GET_SIZE
(
self
->
fut_callbacks
);
i
++
)
{
for
(
i
=
0
;
i
<
PyList_GET_SIZE
(
self
->
fut_callbacks
);
i
++
)
{
int
ret
;
int
ret
;
PyObject
*
item
=
PyList_GET_ITEM
(
self
->
fut_callbacks
,
i
);
PyObject
*
item
=
PyList_GET_ITEM
(
self
->
fut_callbacks
,
i
);
Py_INCREF
(
item
);
if
((
ret
=
PyObject_RichCompareBool
(
fn
,
item
,
Py_EQ
))
<
0
)
{
ret
=
PyObject_RichCompareBool
(
fn
,
item
,
Py_EQ
);
goto
fail
;
}
if
(
ret
==
0
)
{
if
(
ret
==
0
)
{
if
(
j
<
len
)
{
if
(
j
<
len
)
{
Py_INCREF
(
item
);
PyList_SET_ITEM
(
newlist
,
j
,
item
);
PyList_SET_ITEM
(
newlist
,
j
,
item
);
j
++
;
j
++
;
continue
;
}
}
else
{
ret
=
PyList_Append
(
newlist
,
item
);
if
(
PyList_Append
(
newlist
,
item
))
{
goto
fail
;
}
}
}
Py_DECREF
(
item
);
if
(
ret
<
0
)
{
goto
fail
;
}
}
}
}
if
(
PyList_SetSlice
(
newlist
,
j
,
len
,
NULL
)
<
0
)
{
if
(
j
<
len
)
{
goto
fail
;
Py_SIZE
(
newlist
)
=
j
;
}
}
j
=
PyList_GET_SIZE
(
newlist
);
len
=
PyList_GET_SIZE
(
self
->
fut_callbacks
);
if
(
j
!=
len
)
{
if
(
PyList_SetSlice
(
self
->
fut_callbacks
,
0
,
len
,
newlist
)
<
0
)
{
if
(
PyList_SetSlice
(
self
->
fut_callbacks
,
0
,
len
,
newlist
)
<
0
)
{
goto
fail
;
goto
fail
;
}
}
}
Py_DECREF
(
newlist
);
Py_DECREF
(
newlist
);
return
PyLong_FromSsize_t
(
len
-
j
);
return
PyLong_FromSsize_t
(
len
-
j
);
...
@@ -730,7 +727,7 @@ FutureObj_get_state(FutureObj *fut)
...
@@ -730,7 +727,7 @@ FutureObj_get_state(FutureObj *fut)
default:
default:
assert
(
0
);
assert
(
0
);
}
}
Py_INCREF
(
ret
);
Py_
X
INCREF
(
ret
);
return
ret
;
return
ret
;
}
}
...
@@ -766,25 +763,14 @@ FutureObj_repr(FutureObj *fut)
...
@@ -766,25 +763,14 @@ FutureObj_repr(FutureObj *fut)
{
{
_Py_IDENTIFIER
(
_repr_info
);
_Py_IDENTIFIER
(
_repr_info
);
PyObject
*
_repr_info
=
_PyUnicode_FromId
(
&
PyId__repr_info
);
// borrowed
PyObject
*
rinfo
=
_PyObject_CallMethodIdObjArgs
((
PyObject
*
)
fut
,
if
(
_repr_info
==
NULL
)
{
&
PyId__repr_info
,
return
NULL
;
}
PyObject
*
rinfo
=
PyObject_CallMethodObjArgs
((
PyObject
*
)
fut
,
_repr_info
,
NULL
);
NULL
);
if
(
rinfo
==
NULL
)
{
if
(
rinfo
==
NULL
)
{
return
NULL
;
return
NULL
;
}
}
PyObject
*
sp
=
PyUnicode_FromString
(
" "
);
PyObject
*
rinfo_s
=
PyUnicode_Join
(
NULL
,
rinfo
);
if
(
sp
==
NULL
)
{
Py_DECREF
(
rinfo
);
return
NULL
;
}
PyObject
*
rinfo_s
=
PyUnicode_Join
(
sp
,
rinfo
);
Py_DECREF
(
sp
);
Py_DECREF
(
rinfo
);
Py_DECREF
(
rinfo
);
if
(
rinfo_s
==
NULL
)
{
if
(
rinfo_s
==
NULL
)
{
return
NULL
;
return
NULL
;
...
@@ -794,7 +780,7 @@ FutureObj_repr(FutureObj *fut)
...
@@ -794,7 +780,7 @@ FutureObj_repr(FutureObj *fut)
PyObject
*
type_name
=
PyObject_GetAttrString
((
PyObject
*
)
Py_TYPE
(
fut
),
PyObject
*
type_name
=
PyObject_GetAttrString
((
PyObject
*
)
Py_TYPE
(
fut
),
"__name__"
);
"__name__"
);
if
(
type_name
!=
NULL
)
{
if
(
type_name
!=
NULL
)
{
rstr
=
PyUnicode_FromFormat
(
"<%S %
S
>"
,
type_name
,
rinfo_s
);
rstr
=
PyUnicode_FromFormat
(
"<%S %
U
>"
,
type_name
,
rinfo_s
);
Py_DECREF
(
type_name
);
Py_DECREF
(
type_name
);
}
}
Py_DECREF
(
rinfo_s
);
Py_DECREF
(
rinfo_s
);
...
@@ -810,22 +796,21 @@ FutureObj_finalize(FutureObj *fut)
...
@@ -810,22 +796,21 @@ FutureObj_finalize(FutureObj *fut)
_Py_IDENTIFIER
(
future
);
_Py_IDENTIFIER
(
future
);
_Py_IDENTIFIER
(
source_traceback
);
_Py_IDENTIFIER
(
source_traceback
);
PyObject
*
error_type
,
*
error_value
,
*
error_traceback
;
PyObject
*
context
;
PyObject
*
type_name
;
PyObject
*
message
=
NULL
;
PyObject
*
func
;
if
(
!
fut
->
fut_log_tb
)
{
if
(
!
fut
->
fut_log_tb
)
{
return
;
return
;
}
}
assert
(
fut
->
fut_exception
!=
NULL
);
assert
(
fut
->
fut_exception
!=
NULL
);
fut
->
fut_log_tb
=
0
;
;
fut
->
fut_log_tb
=
0
;
PyObject
*
error_type
,
*
error_value
,
*
error_traceback
;
/* Save the current exception, if any. */
/* Save the current exception, if any. */
PyErr_Fetch
(
&
error_type
,
&
error_value
,
&
error_traceback
);
PyErr_Fetch
(
&
error_type
,
&
error_value
,
&
error_traceback
);
PyObject
*
context
=
NULL
;
PyObject
*
type_name
=
NULL
;
PyObject
*
message
=
NULL
;
PyObject
*
func
=
NULL
;
PyObject
*
res
=
NULL
;
context
=
PyDict_New
();
context
=
PyDict_New
();
if
(
context
==
NULL
)
{
if
(
context
==
NULL
)
{
goto
finally
;
goto
finally
;
...
@@ -838,6 +823,7 @@ FutureObj_finalize(FutureObj *fut)
...
@@ -838,6 +823,7 @@ FutureObj_finalize(FutureObj *fut)
message
=
PyUnicode_FromFormat
(
message
=
PyUnicode_FromFormat
(
"%S exception was never retrieved"
,
type_name
);
"%S exception was never retrieved"
,
type_name
);
Py_DECREF
(
type_name
);
if
(
message
==
NULL
)
{
if
(
message
==
NULL
)
{
goto
finally
;
goto
finally
;
}
}
...
@@ -856,18 +842,19 @@ FutureObj_finalize(FutureObj *fut)
...
@@ -856,18 +842,19 @@ FutureObj_finalize(FutureObj *fut)
func
=
_PyObject_GetAttrId
(
fut
->
fut_loop
,
&
PyId_call_exception_handler
);
func
=
_PyObject_GetAttrId
(
fut
->
fut_loop
,
&
PyId_call_exception_handler
);
if
(
func
!=
NULL
)
{
if
(
func
!=
NULL
)
{
res
=
PyObject_CallFunctionObjArgs
(
func
,
context
,
NULL
);
PyObject
*
res
=
PyObject_CallFunctionObjArgs
(
func
,
context
,
NULL
);
if
(
res
==
NULL
)
{
if
(
res
==
NULL
)
{
PyErr_WriteUnraisable
(
func
);
PyErr_WriteUnraisable
(
func
);
}
}
else
{
Py_DECREF
(
res
);
}
Py_DECREF
(
func
);
}
}
finally:
finally:
Py_CLEAR
(
context
);
Py_XDECREF
(
context
);
Py_CLEAR
(
type_name
);
Py_XDECREF
(
message
);
Py_CLEAR
(
message
);
Py_CLEAR
(
func
);
Py_CLEAR
(
res
);
/* Restore the saved exception. */
/* Restore the saved exception. */
PyErr_Restore
(
error_type
,
error_value
,
error_traceback
);
PyErr_Restore
(
error_type
,
error_value
,
error_traceback
);
...
@@ -1014,22 +1001,19 @@ FutureIter_iternext(futureiterobject *it)
...
@@ -1014,22 +1001,19 @@ FutureIter_iternext(futureiterobject *it)
Py_INCREF
(
fut
);
Py_INCREF
(
fut
);
return
(
PyObject
*
)
fut
;
return
(
PyObject
*
)
fut
;
}
}
PyErr_
Format
(
PyExc_AssertionError
,
PyErr_
SetString
(
PyExc_AssertionError
,
"yield from wasn't used with future"
);
"yield from wasn't used with future"
);
return
NULL
;
return
NULL
;
}
}
it
->
future
=
NULL
;
res
=
_asyncio_Future_result_impl
(
fut
);
res
=
_asyncio_Future_result_impl
(
fut
);
if
(
res
!=
NULL
)
{
if
(
res
!=
NULL
)
{
/* The result of the Future is not an exception. */
/* The result of the Future is not an exception. */
if
(
_PyGen_SetStopIterationValue
(
res
)
<
0
)
{
(
void
)
_PyGen_SetStopIterationValue
(
res
);
Py_DECREF
(
res
);
return
NULL
;
}
Py_DECREF
(
res
);
Py_DECREF
(
res
);
}
}
it
->
future
=
NULL
;
Py_DECREF
(
fut
);
Py_DECREF
(
fut
);
return
NULL
;
return
NULL
;
}
}
...
@@ -1046,7 +1030,7 @@ FutureIter_send(futureiterobject *self, PyObject *unused)
...
@@ -1046,7 +1030,7 @@ FutureIter_send(futureiterobject *self, PyObject *unused)
static
PyObject
*
static
PyObject
*
FutureIter_throw
(
futureiterobject
*
self
,
PyObject
*
args
)
FutureIter_throw
(
futureiterobject
*
self
,
PyObject
*
args
)
{
{
PyObject
*
type
=
NULL
,
*
val
=
NULL
,
*
tb
=
NULL
;
PyObject
*
type
,
*
val
=
NULL
,
*
tb
=
NULL
;
if
(
!
PyArg_ParseTuple
(
args
,
"O|OO"
,
&
type
,
&
val
,
&
tb
))
if
(
!
PyArg_ParseTuple
(
args
,
"O|OO"
,
&
type
,
&
val
,
&
tb
))
return
NULL
;
return
NULL
;
...
@@ -1090,7 +1074,7 @@ FutureIter_throw(futureiterobject *self, PyObject *args)
...
@@ -1090,7 +1074,7 @@ FutureIter_throw(futureiterobject *self, PyObject *args)
PyErr_Restore
(
type
,
val
,
tb
);
PyErr_Restore
(
type
,
val
,
tb
);
return
FutureIter_iternext
(
self
)
;
return
NULL
;
fail:
fail:
Py_DECREF
(
type
);
Py_DECREF
(
type
);
...
@@ -1171,7 +1155,7 @@ static PyObject * task_step(TaskObj *, PyObject *);
...
@@ -1171,7 +1155,7 @@ static PyObject * task_step(TaskObj *, PyObject *);
/* ----- Task._step wrapper */
/* ----- Task._step wrapper */
static
int
static
int
TaskS
endMethWrapper_clear
(
TaskSend
MethWrapper
*
o
)
TaskS
tepMethWrapper_clear
(
TaskStep
MethWrapper
*
o
)
{
{
Py_CLEAR
(
o
->
sw_task
);
Py_CLEAR
(
o
->
sw_task
);
Py_CLEAR
(
o
->
sw_arg
);
Py_CLEAR
(
o
->
sw_arg
);
...
@@ -1179,22 +1163,30 @@ TaskSendMethWrapper_clear(TaskSendMethWrapper *o)
...
@@ -1179,22 +1163,30 @@ TaskSendMethWrapper_clear(TaskSendMethWrapper *o)
}
}
static
void
static
void
TaskS
endMethWrapper_dealloc
(
TaskSend
MethWrapper
*
o
)
TaskS
tepMethWrapper_dealloc
(
TaskStep
MethWrapper
*
o
)
{
{
PyObject_GC_UnTrack
(
o
);
PyObject_GC_UnTrack
(
o
);
(
void
)
TaskS
end
MethWrapper_clear
(
o
);
(
void
)
TaskS
tep
MethWrapper_clear
(
o
);
Py_TYPE
(
o
)
->
tp_free
(
o
);
Py_TYPE
(
o
)
->
tp_free
(
o
);
}
}
static
PyObject
*
static
PyObject
*
TaskS
endMethWrapper_call
(
TaskSend
MethWrapper
*
o
,
TaskS
tepMethWrapper_call
(
TaskStep
MethWrapper
*
o
,
PyObject
*
args
,
PyObject
*
kwds
)
PyObject
*
args
,
PyObject
*
kwds
)
{
{
if
(
kwds
!=
NULL
&&
PyDict_GET_SIZE
(
kwds
)
!=
0
)
{
PyErr_SetString
(
PyExc_TypeError
,
"function takes no keyword arguments"
);
return
NULL
;
}
if
(
args
!=
NULL
&&
PyTuple_GET_SIZE
(
args
)
!=
0
)
{
PyErr_SetString
(
PyExc_TypeError
,
"function takes no positional arguments"
);
return
NULL
;
}
return
task_call_step
(
o
->
sw_task
,
o
->
sw_arg
);
return
task_call_step
(
o
->
sw_task
,
o
->
sw_arg
);
}
}
static
int
static
int
TaskS
endMethWrapper_traverse
(
TaskSend
MethWrapper
*
o
,
TaskS
tepMethWrapper_traverse
(
TaskStep
MethWrapper
*
o
,
visitproc
visit
,
void
*
arg
)
visitproc
visit
,
void
*
arg
)
{
{
Py_VISIT
(
o
->
sw_task
);
Py_VISIT
(
o
->
sw_task
);
...
@@ -1203,7 +1195,7 @@ TaskSendMethWrapper_traverse(TaskSendMethWrapper *o,
...
@@ -1203,7 +1195,7 @@ TaskSendMethWrapper_traverse(TaskSendMethWrapper *o,
}
}
static
PyObject
*
static
PyObject
*
TaskS
endMethWrapper_get___self__
(
TaskSend
MethWrapper
*
o
)
TaskS
tepMethWrapper_get___self__
(
TaskStep
MethWrapper
*
o
)
{
{
if
(
o
->
sw_task
)
{
if
(
o
->
sw_task
)
{
Py_INCREF
(
o
->
sw_task
);
Py_INCREF
(
o
->
sw_task
);
...
@@ -1212,30 +1204,30 @@ TaskSendMethWrapper_get___self__(TaskSendMethWrapper *o)
...
@@ -1212,30 +1204,30 @@ TaskSendMethWrapper_get___self__(TaskSendMethWrapper *o)
Py_RETURN_NONE
;
Py_RETURN_NONE
;
}
}
static
PyGetSetDef
TaskS
end
MethWrapper_getsetlist
[]
=
{
static
PyGetSetDef
TaskS
tep
MethWrapper_getsetlist
[]
=
{
{
"__self__"
,
(
getter
)
TaskS
end
MethWrapper_get___self__
,
NULL
,
NULL
},
{
"__self__"
,
(
getter
)
TaskS
tep
MethWrapper_get___self__
,
NULL
,
NULL
},
{
NULL
}
/* Sentinel */
{
NULL
}
/* Sentinel */
};
};
PyTypeObject
TaskS
end
MethWrapper_Type
=
{
PyTypeObject
TaskS
tep
MethWrapper_Type
=
{
PyVarObject_HEAD_INIT
(
NULL
,
0
)
PyVarObject_HEAD_INIT
(
NULL
,
0
)
"TaskS
end
MethWrapper"
,
"TaskS
tep
MethWrapper"
,
.
tp_basicsize
=
sizeof
(
TaskS
end
MethWrapper
),
.
tp_basicsize
=
sizeof
(
TaskS
tep
MethWrapper
),
.
tp_itemsize
=
0
,
.
tp_itemsize
=
0
,
.
tp_getset
=
TaskS
end
MethWrapper_getsetlist
,
.
tp_getset
=
TaskS
tep
MethWrapper_getsetlist
,
.
tp_dealloc
=
(
destructor
)
TaskS
end
MethWrapper_dealloc
,
.
tp_dealloc
=
(
destructor
)
TaskS
tep
MethWrapper_dealloc
,
.
tp_call
=
(
ternaryfunc
)
TaskS
end
MethWrapper_call
,
.
tp_call
=
(
ternaryfunc
)
TaskS
tep
MethWrapper_call
,
.
tp_getattro
=
PyObject_GenericGetAttr
,
.
tp_getattro
=
PyObject_GenericGetAttr
,
.
tp_flags
=
Py_TPFLAGS_DEFAULT
|
Py_TPFLAGS_HAVE_GC
,
.
tp_flags
=
Py_TPFLAGS_DEFAULT
|
Py_TPFLAGS_HAVE_GC
,
.
tp_traverse
=
(
traverseproc
)
TaskS
end
MethWrapper_traverse
,
.
tp_traverse
=
(
traverseproc
)
TaskS
tep
MethWrapper_traverse
,
.
tp_clear
=
(
inquiry
)
TaskS
end
MethWrapper_clear
,
.
tp_clear
=
(
inquiry
)
TaskS
tep
MethWrapper_clear
,
};
};
static
PyObject
*
static
PyObject
*
TaskS
end
MethWrapper_new
(
TaskObj
*
task
,
PyObject
*
arg
)
TaskS
tep
MethWrapper_new
(
TaskObj
*
task
,
PyObject
*
arg
)
{
{
TaskS
end
MethWrapper
*
o
;
TaskS
tep
MethWrapper
*
o
;
o
=
PyObject_GC_New
(
TaskS
endMethWrapper
,
&
TaskSend
MethWrapper_Type
);
o
=
PyObject_GC_New
(
TaskS
tepMethWrapper
,
&
TaskStep
MethWrapper_Type
);
if
(
o
==
NULL
)
{
if
(
o
==
NULL
)
{
return
NULL
;
return
NULL
;
}
}
...
@@ -1258,7 +1250,11 @@ TaskWakeupMethWrapper_call(TaskWakeupMethWrapper *o,
...
@@ -1258,7 +1250,11 @@ TaskWakeupMethWrapper_call(TaskWakeupMethWrapper *o,
{
{
PyObject
*
fut
;
PyObject
*
fut
;
if
(
!
PyArg_ParseTuple
(
args
,
"O|"
,
&
fut
))
{
if
(
kwds
!=
NULL
&&
PyDict_GET_SIZE
(
kwds
)
!=
0
)
{
PyErr_SetString
(
PyExc_TypeError
,
"function takes no keyword arguments"
);
return
NULL
;
}
if
(
!
PyArg_ParseTuple
(
args
,
"O"
,
&
fut
))
{
return
NULL
;
return
NULL
;
}
}
...
@@ -1322,16 +1318,16 @@ TaskWakeupMethWrapper_new(TaskObj *task)
...
@@ -1322,16 +1318,16 @@ TaskWakeupMethWrapper_new(TaskObj *task)
/*[clinic input]
/*[clinic input]
_asyncio.Task.__init__
_asyncio.Task.__init__
coro:
'O'
coro:
object
*
*
loop:
'O' = NULL
loop:
object = None
A coroutine wrapped in a Future.
A coroutine wrapped in a Future.
[clinic start generated code]*/
[clinic start generated code]*/
static
int
static
int
_asyncio_Task___init___impl
(
TaskObj
*
self
,
PyObject
*
coro
,
PyObject
*
loop
)
_asyncio_Task___init___impl
(
TaskObj
*
self
,
PyObject
*
coro
,
PyObject
*
loop
)
/*[clinic end generated code: output=9f24774c2287fc2f input=
71d8d28c201a18cd
]*/
/*[clinic end generated code: output=9f24774c2287fc2f input=
8d132974b049593e
]*/
{
{
PyObject
*
res
;
PyObject
*
res
;
_Py_IDENTIFIER
(
add
);
_Py_IDENTIFIER
(
add
);
...
@@ -1437,7 +1433,7 @@ TaskObj_get_fut_waiter(TaskObj *task)
...
@@ -1437,7 +1433,7 @@ TaskObj_get_fut_waiter(TaskObj *task)
@classmethod
@classmethod
_asyncio.Task.current_task
_asyncio.Task.current_task
loop:
'O'
= None
loop:
object
= None
Return the currently running task in an event loop or None.
Return the currently running task in an event loop or None.
...
@@ -1448,7 +1444,7 @@ None is returned when called not in the context of a Task.
...
@@ -1448,7 +1444,7 @@ None is returned when called not in the context of a Task.
static
PyObject
*
static
PyObject
*
_asyncio_Task_current_task_impl
(
PyTypeObject
*
type
,
PyObject
*
loop
)
_asyncio_Task_current_task_impl
(
PyTypeObject
*
type
,
PyObject
*
loop
)
/*[clinic end generated code: output=99fbe7332c516e03 input=
a0d6cdf2e3b243e1
]*/
/*[clinic end generated code: output=99fbe7332c516e03 input=
cd14770c5b79c7eb
]*/
{
{
PyObject
*
res
;
PyObject
*
res
;
...
@@ -1510,12 +1506,14 @@ task_all_tasks(PyObject *loop)
...
@@ -1510,12 +1506,14 @@ task_all_tasks(PyObject *loop)
Py_DECREF
(
task_loop
);
Py_DECREF
(
task_loop
);
Py_DECREF
(
task
);
Py_DECREF
(
task
);
}
}
if
(
PyErr_Occurred
())
{
goto
fail
;
}
Py_DECREF
(
iter
);
Py_DECREF
(
iter
);
return
set
;
return
set
;
fail:
fail:
Py_
X
DECREF
(
set
);
Py_DECREF
(
set
);
Py_XDECREF
(
iter
);
Py_XDECREF
(
iter
);
return
NULL
;
return
NULL
;
}
}
...
@@ -1524,7 +1522,7 @@ fail:
...
@@ -1524,7 +1522,7 @@ fail:
@classmethod
@classmethod
_asyncio.Task.all_tasks
_asyncio.Task.all_tasks
loop:
'O'
= None
loop:
object
= None
Return a set of all tasks for an event loop.
Return a set of all tasks for an event loop.
...
@@ -1533,7 +1531,7 @@ By default all tasks for the current event loop are returned.
...
@@ -1533,7 +1531,7 @@ By default all tasks for the current event loop are returned.
static
PyObject
*
static
PyObject
*
_asyncio_Task_all_tasks_impl
(
PyTypeObject
*
type
,
PyObject
*
loop
)
_asyncio_Task_all_tasks_impl
(
PyTypeObject
*
type
,
PyObject
*
loop
)
/*[clinic end generated code: output=11f9b20749ccca5d input=
c6f5b53bd487488f
]*/
/*[clinic end generated code: output=11f9b20749ccca5d input=
497f80bc9ce726b5
]*/
{
{
PyObject
*
res
;
PyObject
*
res
;
...
@@ -1627,7 +1625,7 @@ _asyncio_Task_cancel_impl(TaskObj *self)
...
@@ -1627,7 +1625,7 @@ _asyncio_Task_cancel_impl(TaskObj *self)
_asyncio.Task.get_stack
_asyncio.Task.get_stack
*
*
limit:
'O'
= None
limit:
object
= None
Return the list of stack frames for this task's coroutine.
Return the list of stack frames for this task's coroutine.
...
@@ -1652,7 +1650,7 @@ returned for a suspended coroutine.
...
@@ -1652,7 +1650,7 @@ returned for a suspended coroutine.
static
PyObject
*
static
PyObject
*
_asyncio_Task_get_stack_impl
(
TaskObj
*
self
,
PyObject
*
limit
)
_asyncio_Task_get_stack_impl
(
TaskObj
*
self
,
PyObject
*
limit
)
/*[clinic end generated code: output=c9aeeeebd1e18118 input=
b1920230a766d17a
]*/
/*[clinic end generated code: output=c9aeeeebd1e18118 input=
05b323d42b809b90
]*/
{
{
return
PyObject_CallFunctionObjArgs
(
return
PyObject_CallFunctionObjArgs
(
asyncio_task_get_stack_func
,
self
,
limit
,
NULL
);
asyncio_task_get_stack_func
,
self
,
limit
,
NULL
);
...
@@ -1662,8 +1660,8 @@ _asyncio_Task_get_stack_impl(TaskObj *self, PyObject *limit)
...
@@ -1662,8 +1660,8 @@ _asyncio_Task_get_stack_impl(TaskObj *self, PyObject *limit)
_asyncio.Task.print_stack
_asyncio.Task.print_stack
*
*
limit:
'O'
= None
limit:
object
= None
file:
'O'
= None
file:
object
= None
Print the stack or traceback for this task's coroutine.
Print the stack or traceback for this task's coroutine.
...
@@ -1677,7 +1675,7 @@ to sys.stderr.
...
@@ -1677,7 +1675,7 @@ to sys.stderr.
static
PyObject
*
static
PyObject
*
_asyncio_Task_print_stack_impl
(
TaskObj
*
self
,
PyObject
*
limit
,
_asyncio_Task_print_stack_impl
(
TaskObj
*
self
,
PyObject
*
limit
,
PyObject
*
file
)
PyObject
*
file
)
/*[clinic end generated code: output=7339e10314cd3f4d input=1
9f1e99ab5400bc3
]*/
/*[clinic end generated code: output=7339e10314cd3f4d input=1
a0352913b7fcd92
]*/
{
{
return
PyObject_CallFunctionObjArgs
(
return
PyObject_CallFunctionObjArgs
(
asyncio_task_print_stack_func
,
self
,
limit
,
file
,
NULL
);
asyncio_task_print_stack_func
,
self
,
limit
,
file
,
NULL
);
...
@@ -1686,12 +1684,12 @@ _asyncio_Task_print_stack_impl(TaskObj *self, PyObject *limit,
...
@@ -1686,12 +1684,12 @@ _asyncio_Task_print_stack_impl(TaskObj *self, PyObject *limit,
/*[clinic input]
/*[clinic input]
_asyncio.Task._step
_asyncio.Task._step
exc:
'O' = NULL
exc:
object = None
[clinic start generated code]*/
[clinic start generated code]*/
static
PyObject
*
static
PyObject
*
_asyncio_Task__step_impl
(
TaskObj
*
self
,
PyObject
*
exc
)
_asyncio_Task__step_impl
(
TaskObj
*
self
,
PyObject
*
exc
)
/*[clinic end generated code: output=7ed23f0cefd5ae42 input=
ada4b2324e5370af
]*/
/*[clinic end generated code: output=7ed23f0cefd5ae42 input=
1e19a985ace87ca4
]*/
{
{
return
task_step
(
self
,
exc
==
Py_None
?
NULL
:
exc
);
return
task_step
(
self
,
exc
==
Py_None
?
NULL
:
exc
);
}
}
...
@@ -1699,12 +1697,12 @@ _asyncio_Task__step_impl(TaskObj *self, PyObject *exc)
...
@@ -1699,12 +1697,12 @@ _asyncio_Task__step_impl(TaskObj *self, PyObject *exc)
/*[clinic input]
/*[clinic input]
_asyncio.Task._wakeup
_asyncio.Task._wakeup
fut:
'O'
fut:
object
[clinic start generated code]*/
[clinic start generated code]*/
static
PyObject
*
static
PyObject
*
_asyncio_Task__wakeup_impl
(
TaskObj
*
self
,
PyObject
*
fut
)
_asyncio_Task__wakeup_impl
(
TaskObj
*
self
,
PyObject
*
fut
)
/*[clinic end generated code: output=75cb341c760fd071 input=
11ee4918a5bdbf21
]*/
/*[clinic end generated code: output=75cb341c760fd071 input=
6a0616406f829a7b
]*/
{
{
return
task_wakeup
(
self
,
fut
);
return
task_wakeup
(
self
,
fut
);
}
}
...
@@ -1717,11 +1715,9 @@ TaskObj_finalize(TaskObj *task)
...
@@ -1717,11 +1715,9 @@ TaskObj_finalize(TaskObj *task)
_Py_IDENTIFIER
(
message
);
_Py_IDENTIFIER
(
message
);
_Py_IDENTIFIER
(
source_traceback
);
_Py_IDENTIFIER
(
source_traceback
);
PyObject
*
context
;
PyObject
*
message
=
NULL
;
PyObject
*
message
=
NULL
;
PyObject
*
context
=
NULL
;
PyObject
*
func
;
PyObject
*
func
=
NULL
;
PyObject
*
res
=
NULL
;
PyObject
*
error_type
,
*
error_value
,
*
error_traceback
;
PyObject
*
error_type
,
*
error_value
,
*
error_traceback
;
if
(
task
->
task_state
!=
STATE_PENDING
||
!
task
->
task_log_destroy_pending
)
{
if
(
task
->
task_state
!=
STATE_PENDING
||
!
task
->
task_log_destroy_pending
)
{
...
@@ -1757,17 +1753,19 @@ TaskObj_finalize(TaskObj *task)
...
@@ -1757,17 +1753,19 @@ TaskObj_finalize(TaskObj *task)
func
=
_PyObject_GetAttrId
(
task
->
task_loop
,
&
PyId_call_exception_handler
);
func
=
_PyObject_GetAttrId
(
task
->
task_loop
,
&
PyId_call_exception_handler
);
if
(
func
!=
NULL
)
{
if
(
func
!=
NULL
)
{
res
=
PyObject_CallFunctionObjArgs
(
func
,
context
,
NULL
);
PyObject
*
res
=
PyObject_CallFunctionObjArgs
(
func
,
context
,
NULL
);
if
(
res
==
NULL
)
{
if
(
res
==
NULL
)
{
PyErr_WriteUnraisable
(
func
);
PyErr_WriteUnraisable
(
func
);
}
}
else
{
Py_DECREF
(
res
);
}
Py_DECREF
(
func
);
}
}
finally:
finally:
Py_CLEAR
(
context
);
Py_XDECREF
(
context
);
Py_CLEAR
(
message
);
Py_XDECREF
(
message
);
Py_CLEAR
(
func
);
Py_CLEAR
(
res
);
/* Restore the saved exception. */
/* Restore the saved exception. */
PyErr_Restore
(
error_type
,
error_value
,
error_traceback
);
PyErr_Restore
(
error_type
,
error_value
,
error_traceback
);
...
@@ -1879,9 +1877,6 @@ task_call_step(TaskObj *task, PyObject *arg)
...
@@ -1879,9 +1877,6 @@ task_call_step(TaskObj *task, PyObject *arg)
}
}
else
{
else
{
/* `task` is a subclass of Task */
/* `task` is a subclass of Task */
if
(
arg
==
NULL
)
{
arg
=
Py_None
;
}
return
_PyObject_CallMethodIdObjArgs
((
PyObject
*
)
task
,
&
PyId__step
,
return
_PyObject_CallMethodIdObjArgs
((
PyObject
*
)
task
,
&
PyId__step
,
arg
,
NULL
);
arg
,
NULL
);
}
}
...
@@ -1892,7 +1887,7 @@ task_call_step_soon(TaskObj *task, PyObject *arg)
...
@@ -1892,7 +1887,7 @@ task_call_step_soon(TaskObj *task, PyObject *arg)
{
{
PyObject
*
handle
;
PyObject
*
handle
;
PyObject
*
cb
=
TaskS
end
MethWrapper_new
(
task
,
arg
);
PyObject
*
cb
=
TaskS
tep
MethWrapper_new
(
task
,
arg
);
if
(
cb
==
NULL
)
{
if
(
cb
==
NULL
)
{
return
-
1
;
return
-
1
;
}
}
...
@@ -1947,7 +1942,7 @@ task_step_impl(TaskObj *task, PyObject *exc)
...
@@ -1947,7 +1942,7 @@ task_step_impl(TaskObj *task, PyObject *exc)
int
res
;
int
res
;
int
clear_exc
=
0
;
int
clear_exc
=
0
;
PyObject
*
result
=
NULL
;
PyObject
*
result
=
NULL
;
PyObject
*
coro
=
task
->
task_coro
;
PyObject
*
coro
;
PyObject
*
o
;
PyObject
*
o
;
if
(
task
->
task_state
!=
STATE_PENDING
)
{
if
(
task
->
task_state
!=
STATE_PENDING
)
{
...
@@ -1988,6 +1983,12 @@ task_step_impl(TaskObj *task, PyObject *exc)
...
@@ -1988,6 +1983,12 @@ task_step_impl(TaskObj *task, PyObject *exc)
Py_CLEAR
(
task
->
task_fut_waiter
);
Py_CLEAR
(
task
->
task_fut_waiter
);
coro
=
task
->
task_coro
;
if
(
coro
==
NULL
)
{
PyErr_SetString
(
PyExc_RuntimeError
,
"uninitialized Task object"
);
return
NULL
;
}
if
(
exc
==
NULL
)
{
if
(
exc
==
NULL
)
{
if
(
PyGen_CheckExact
(
coro
)
||
PyCoro_CheckExact
(
coro
))
{
if
(
PyGen_CheckExact
(
coro
)
||
PyCoro_CheckExact
(
coro
))
{
result
=
_PyGen_Send
((
PyGenObject
*
)
coro
,
Py_None
);
result
=
_PyGen_Send
((
PyGenObject
*
)
coro
,
Py_None
);
...
@@ -2002,7 +2003,7 @@ task_step_impl(TaskObj *task, PyObject *exc)
...
@@ -2002,7 +2003,7 @@ task_step_impl(TaskObj *task, PyObject *exc)
exc
,
NULL
);
exc
,
NULL
);
if
(
clear_exc
)
{
if
(
clear_exc
)
{
/* We created 'exc' during this call */
/* We created 'exc' during this call */
Py_
CLEAR
(
exc
);
Py_
DECREF
(
exc
);
}
}
}
}
...
@@ -2051,13 +2052,13 @@ set_exception:
...
@@ -2051,13 +2052,13 @@ set_exception:
o
=
future_set_exception
((
FutureObj
*
)
task
,
ev
);
o
=
future_set_exception
((
FutureObj
*
)
task
,
ev
);
if
(
!
o
)
{
if
(
!
o
)
{
/* An exception in Task.set_exception() */
/* An exception in Task.set_exception() */
Py_
X
DECREF
(
et
);
Py_DECREF
(
et
);
Py_XDECREF
(
tb
);
Py_XDECREF
(
tb
);
Py_XDECREF
(
ev
);
Py_XDECREF
(
ev
);
goto
fail
;
goto
fail
;
}
}
assert
(
o
==
Py_None
);
assert
(
o
==
Py_None
);
Py_
CLEAR
(
o
);
Py_
DECREF
(
o
);
if
(
!
PyErr_GivenExceptionMatches
(
et
,
PyExc_Exception
))
{
if
(
!
PyErr_GivenExceptionMatches
(
et
,
PyExc_Exception
))
{
/* We've got a BaseException; re-raise it */
/* We've got a BaseException; re-raise it */
...
@@ -2065,7 +2066,7 @@ set_exception:
...
@@ -2065,7 +2066,7 @@ set_exception:
goto
fail
;
goto
fail
;
}
}
Py_
X
DECREF
(
et
);
Py_DECREF
(
et
);
Py_XDECREF
(
tb
);
Py_XDECREF
(
tb
);
Py_XDECREF
(
ev
);
Py_XDECREF
(
ev
);
...
@@ -2137,7 +2138,7 @@ set_exception:
...
@@ -2137,7 +2138,7 @@ set_exception:
}
}
else
{
else
{
if
(
o
==
Py_None
)
{
if
(
o
==
Py_None
)
{
Py_
CLEAR
(
o
);
Py_
DECREF
(
o
);
}
}
else
{
else
{
/* `result` is a Future-compatible object */
/* `result` is a Future-compatible object */
...
@@ -2145,7 +2146,7 @@ set_exception:
...
@@ -2145,7 +2146,7 @@ set_exception:
PyObject
*
res
;
PyObject
*
res
;
int
blocking
=
PyObject_IsTrue
(
o
);
int
blocking
=
PyObject_IsTrue
(
o
);
Py_
CLEAR
(
o
);
Py_
DECREF
(
o
);
if
(
blocking
<
0
)
{
if
(
blocking
<
0
)
{
goto
fail
;
goto
fail
;
}
}
...
@@ -2228,7 +2229,7 @@ set_exception:
...
@@ -2228,7 +2229,7 @@ set_exception:
goto
fail
;
goto
fail
;
}
}
res
=
PyObject_IsTrue
(
o
);
res
=
PyObject_IsTrue
(
o
);
Py_
CLEAR
(
o
);
Py_
DECREF
(
o
);
if
(
res
==
-
1
)
{
if
(
res
==
-
1
)
{
/* An exception while checking if 'val' is True */
/* An exception while checking if 'val' is True */
goto
fail
;
goto
fail
;
...
@@ -2296,14 +2297,8 @@ task_step(TaskObj *task, PyObject *exc)
...
@@ -2296,14 +2297,8 @@ task_step(TaskObj *task, PyObject *exc)
PyObject
*
et
,
*
ev
,
*
tb
;
PyObject
*
et
,
*
ev
,
*
tb
;
PyErr_Fetch
(
&
et
,
&
ev
,
&
tb
);
PyErr_Fetch
(
&
et
,
&
ev
,
&
tb
);
ot
=
_PyDict_Pop
(
current_tasks
,
task
->
task_loop
,
NULL
);
ot
=
_PyDict_Pop
(
current_tasks
,
task
->
task_loop
,
NULL
);
if
(
ot
==
NULL
)
{
Py_XDECREF
(
ot
);
Py_XDECREF
(
et
);
_PyErr_ChainExceptions
(
et
,
ev
,
tb
);
Py_XDECREF
(
tb
);
Py_XDECREF
(
ev
);
return
NULL
;
}
Py_DECREF
(
ot
);
PyErr_Restore
(
et
,
ev
,
tb
);
return
NULL
;
return
NULL
;
}
}
else
{
else
{
...
@@ -2322,17 +2317,18 @@ task_step(TaskObj *task, PyObject *exc)
...
@@ -2322,17 +2317,18 @@ task_step(TaskObj *task, PyObject *exc)
static
PyObject
*
static
PyObject
*
task_wakeup
(
TaskObj
*
task
,
PyObject
*
o
)
task_wakeup
(
TaskObj
*
task
,
PyObject
*
o
)
{
{
PyObject
*
et
,
*
ev
,
*
tb
;
PyObject
*
result
;
assert
(
o
);
assert
(
o
);
if
(
Future_CheckExact
(
o
)
||
Task_CheckExact
(
o
))
{
if
(
Future_CheckExact
(
o
)
||
Task_CheckExact
(
o
))
{
PyObject
*
fut_result
=
NULL
;
PyObject
*
fut_result
=
NULL
;
int
res
=
future_get_result
((
FutureObj
*
)
o
,
&
fut_result
);
int
res
=
future_get_result
((
FutureObj
*
)
o
,
&
fut_result
);
PyObject
*
result
;
switch
(
res
)
{
switch
(
res
)
{
case
-
1
:
case
-
1
:
assert
(
fut_result
==
NULL
);
assert
(
fut_result
==
NULL
);
return
NULL
;
break
;
/* exception raised */
case
0
:
case
0
:
Py_DECREF
(
fut_result
);
Py_DECREF
(
fut_result
);
return
task_call_step
(
task
,
NULL
);
return
task_call_step
(
task
,
NULL
);
...
@@ -2343,29 +2339,32 @@ task_wakeup(TaskObj *task, PyObject *o)
...
@@ -2343,29 +2339,32 @@ task_wakeup(TaskObj *task, PyObject *o)
return
result
;
return
result
;
}
}
}
}
else
{
PyObject
*
fut_result
=
PyObject_CallMethod
(
o
,
"result"
,
NULL
);
PyObject
*
fut_result
=
PyObject_CallMethod
(
o
,
"result"
,
NULL
);
if
(
fut_result
==
NULL
)
{
if
(
fut_result
!=
NULL
)
{
PyObject
*
et
,
*
ev
,
*
tb
;
Py_DECREF
(
fut_result
);
PyObject
*
res
;
return
task_call_step
(
task
,
NULL
);
}
/* exception raised */
}
PyErr_Fetch
(
&
et
,
&
ev
,
&
tb
);
PyErr_Fetch
(
&
et
,
&
ev
,
&
tb
);
if
(
!
PyErr_GivenExceptionMatches
(
et
,
PyExc_Exception
))
{
/* We've got a BaseException; re-raise it */
PyErr_Restore
(
et
,
ev
,
tb
);
return
NULL
;
}
if
(
!
ev
||
!
PyObject_TypeCheck
(
ev
,
(
PyTypeObject
*
)
et
))
{
if
(
!
ev
||
!
PyObject_TypeCheck
(
ev
,
(
PyTypeObject
*
)
et
))
{
PyErr_NormalizeException
(
&
et
,
&
ev
,
&
tb
);
PyErr_NormalizeException
(
&
et
,
&
ev
,
&
tb
);
}
}
res
=
task_call_step
(
task
,
ev
);
result
=
task_call_step
(
task
,
ev
);
Py_X
DECREF
(
et
);
Py_
DECREF
(
et
);
Py_XDECREF
(
tb
);
Py_XDECREF
(
tb
);
Py_XDECREF
(
ev
);
Py_XDECREF
(
ev
);
return
res
;
return
result
;
}
else
{
Py_DECREF
(
fut_result
);
return
task_call_step
(
task
,
NULL
);
}
}
}
...
@@ -2398,7 +2397,7 @@ module_init(void)
...
@@ -2398,7 +2397,7 @@ module_init(void)
Py_CLEAR(module); \
Py_CLEAR(module); \
module = PyImport_ImportModule(NAME); \
module = PyImport_ImportModule(NAME); \
if (module == NULL) { \
if (module == NULL) { \
return -1
; \
goto fail
; \
}
}
#define GET_MOD_ATTR(VAR, NAME) \
#define GET_MOD_ATTR(VAR, NAME) \
...
@@ -2429,7 +2428,7 @@ module_init(void)
...
@@ -2429,7 +2428,7 @@ module_init(void)
WITH_MOD
(
"weakref"
)
WITH_MOD
(
"weakref"
)
GET_MOD_ATTR
(
cls
,
"WeakSet"
)
GET_MOD_ATTR
(
cls
,
"WeakSet"
)
all_tasks
=
_PyObject_CallNoArg
(
cls
);
all_tasks
=
_PyObject_CallNoArg
(
cls
);
Py_
CLEAR
(
cls
);
Py_
DECREF
(
cls
);
if
(
all_tasks
==
NULL
)
{
if
(
all_tasks
==
NULL
)
{
goto
fail
;
goto
fail
;
}
}
...
@@ -2439,7 +2438,7 @@ module_init(void)
...
@@ -2439,7 +2438,7 @@ module_init(void)
goto
fail
;
goto
fail
;
}
}
Py_
CLEAR
(
module
);
Py_
DECREF
(
module
);
return
0
;
return
0
;
fail:
fail:
...
@@ -2478,7 +2477,7 @@ PyInit__asyncio(void)
...
@@ -2478,7 +2477,7 @@ PyInit__asyncio(void)
if
(
PyType_Ready
(
&
FutureIterType
)
<
0
)
{
if
(
PyType_Ready
(
&
FutureIterType
)
<
0
)
{
return
NULL
;
return
NULL
;
}
}
if
(
PyType_Ready
(
&
TaskS
end
MethWrapper_Type
)
<
0
)
{
if
(
PyType_Ready
(
&
TaskS
tep
MethWrapper_Type
)
<
0
)
{
return
NULL
;
return
NULL
;
}
}
if
(
PyType_Ready
(
&
TaskWakeupMethWrapper_Type
)
<
0
)
{
if
(
PyType_Ready
(
&
TaskWakeupMethWrapper_Type
)
<
0
)
{
...
...
Modules/clinic/_asynciomodule.c.h
Dosyayı görüntüle @
bca4939d
...
@@ -28,7 +28,7 @@ _asyncio_Future___init__(PyObject *self, PyObject *args, PyObject *kwargs)
...
@@ -28,7 +28,7 @@ _asyncio_Future___init__(PyObject *self, PyObject *args, PyObject *kwargs)
int
return_value
=
-
1
;
int
return_value
=
-
1
;
static
const
char
*
const
_keywords
[]
=
{
"loop"
,
NULL
};
static
const
char
*
const
_keywords
[]
=
{
"loop"
,
NULL
};
static
_PyArg_Parser
_parser
=
{
"|$O:Future"
,
_keywords
,
0
};
static
_PyArg_Parser
_parser
=
{
"|$O:Future"
,
_keywords
,
0
};
PyObject
*
loop
=
NULL
;
PyObject
*
loop
=
Py_None
;
if
(
!
_PyArg_ParseTupleAndKeywordsFast
(
args
,
kwargs
,
&
_parser
,
if
(
!
_PyArg_ParseTupleAndKeywordsFast
(
args
,
kwargs
,
&
_parser
,
&
loop
))
{
&
loop
))
{
...
@@ -244,7 +244,7 @@ _asyncio_Task___init__(PyObject *self, PyObject *args, PyObject *kwargs)
...
@@ -244,7 +244,7 @@ _asyncio_Task___init__(PyObject *self, PyObject *args, PyObject *kwargs)
static
const
char
*
const
_keywords
[]
=
{
"coro"
,
"loop"
,
NULL
};
static
const
char
*
const
_keywords
[]
=
{
"coro"
,
"loop"
,
NULL
};
static
_PyArg_Parser
_parser
=
{
"O|$O:Task"
,
_keywords
,
0
};
static
_PyArg_Parser
_parser
=
{
"O|$O:Task"
,
_keywords
,
0
};
PyObject
*
coro
;
PyObject
*
coro
;
PyObject
*
loop
=
NULL
;
PyObject
*
loop
=
Py_None
;
if
(
!
_PyArg_ParseTupleAndKeywordsFast
(
args
,
kwargs
,
&
_parser
,
if
(
!
_PyArg_ParseTupleAndKeywordsFast
(
args
,
kwargs
,
&
_parser
,
&
coro
,
&
loop
))
{
&
coro
,
&
loop
))
{
...
@@ -477,7 +477,7 @@ _asyncio_Task__step(TaskObj *self, PyObject **args, Py_ssize_t nargs, PyObject *
...
@@ -477,7 +477,7 @@ _asyncio_Task__step(TaskObj *self, PyObject **args, Py_ssize_t nargs, PyObject *
PyObject
*
return_value
=
NULL
;
PyObject
*
return_value
=
NULL
;
static
const
char
*
const
_keywords
[]
=
{
"exc"
,
NULL
};
static
const
char
*
const
_keywords
[]
=
{
"exc"
,
NULL
};
static
_PyArg_Parser
_parser
=
{
"|O:_step"
,
_keywords
,
0
};
static
_PyArg_Parser
_parser
=
{
"|O:_step"
,
_keywords
,
0
};
PyObject
*
exc
=
NULL
;
PyObject
*
exc
=
Py_None
;
if
(
!
_PyArg_ParseStackAndKeywords
(
args
,
nargs
,
kwnames
,
&
_parser
,
if
(
!
_PyArg_ParseStackAndKeywords
(
args
,
nargs
,
kwnames
,
&
_parser
,
&
exc
))
{
&
exc
))
{
...
@@ -517,4 +517,4 @@ _asyncio_Task__wakeup(TaskObj *self, PyObject **args, Py_ssize_t nargs, PyObject
...
@@ -517,4 +517,4 @@ _asyncio_Task__wakeup(TaskObj *self, PyObject **args, Py_ssize_t nargs, PyObject
exit:
exit:
return
return_value
;
return
return_value
;
}
}
/*[clinic end generated code: output=
fe651840e0466fa9
input=a9049054013a1b77]*/
/*[clinic end generated code: output=
b92f9cd2b9fb37ef
input=a9049054013a1b77]*/
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