Path: eternal-september.org!news.eternal-september.org!feeder3.eternal-september.org!fu-berlin.de!uni-berlin.de!not-for-mail From: ram@zedat.fu-berlin.de (Stefan Ram) Newsgroups: comp.lang.python Subject: Re: Await expressions (Posting On Python-List Prohibited) Date: 26 Jan 2024 21:46:47 GMT Organization: Stefan Ram Lines: 26 Expires: 1 Dec 2024 11:59:58 GMT Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Trace: news.uni-berlin.de B1FdWp+kuU0eqQ4f4uaXBQoa+Kh445OO77rAlpO+7MvQOG Cancel-Lock: sha1:761skRci7FQDcJKPhalZyeD2Muk= sha256:KHERMsq516mJQqxxDihz+3VTtyqDbBcNDCAZDB/nk7M= X-Copyright: (C) Copyright 2024 Stefan Ram. All rights reserved. Distribution through any means other than regular usenet channels is forbidden. It is forbidden to publish this article in the Web, to change URIs of this article into links, and to transfer the body without this notice, but quotations of parts in other Usenet posts are allowed. X-No-Archive: Yes Archive: no X-No-Archive-Readme: "X-No-Archive" is set, because this prevents some services to mirror the article in the web. But the article may be kept on a Usenet archive server with only NNTP access. X-No-Html: yes Content-Language: en-US Accept-Language: de-DE-1901, en-US, it, fr-FR Lawrence D'Oliveiro 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?