Sujet : Re: Await expressions (Posting On Python-List Prohibited)
De : ram (at) *nospam* zedat.fu-berlin.de (Stefan Ram)
Groupes : comp.lang.pythonDate : 26. Jan 2024, 22:46:47
Autres entêtes
Organisation : Stefan Ram
Message-ID : <specification-20240126223958@ram.dialup.fu-berlin.de>
References : 1 2
Lawrence D'Oliveiro <
ldo@nz.invalid> writes:
On 26 Jan 2024 18:36:50 GMT, Stefan Ram wrote:
In "The Python Language Reference, Release 3.13.0a0",
there is this section:
|6.4 Await expression |
|Suspend the execution of coroutine on an awaitable object.
|Can only be used inside a coroutine function.
|await_expr ::= "await" primary |
...
- What does it mean to "suspend something on something"?
It returns control to the point of execution of the .send method that
(directly or indirectly) started or resumed the coroutine execution.
Thank you!
The specification said: "suspend the execution of coroutine on
an awaitable object".
You said this: "returns control to the point of execution of the
.send method that (directly or indirectly) started or resumed
the coroutine execution.".
But your explanation seems to have no mention of the "something" /
"the awaitable object" part following the preposition "on". Shouldn't
this awaitable object play a rôle in the explanation of what happens?