Title
co_await in a lambda-expression
Status
drwp
Section
7.6.2.4 [expr.await]
Submitter
Jim X

Created on 2022-12-12.00:00:00 last changed 3 months ago

Messages

Date: 2023-11-16.21:27:26

Proposed resolution (approved by CWG 2023-11-11):

Change in 7.6.2.4 [expr.await] paragraph 2 as follows:

An await-expression shall appear only in as a potentially-evaluated expression within the compound-statement of a function-body or lambda-expression, in either case outside of a handler (14.1 [except.pre]). ...
Date: 2024-03-15.00:00:00

[Accepted as a DR at the March, 2024 meeting.]

Subclause 7.6.2.4 [expr.await] paragraph 2 disallows an await-expression to appear in the body of a lambda-expression:

An await-expression shall appear only in a potentially-evaluated expression within the compound-statement of a function-body outside of a handler (14.1 [except.pre]). ...

This is probably unintended.

History
Date User Action Args
2024-07-20 13:52:34adminsetstatus: dr -> drwp
2024-04-05 21:43:46adminsetstatus: ready -> dr
2024-03-20 14:10:31adminsetstatus: tentatively ready -> ready
2023-11-16 21:27:26adminsetmessages: + msg7518
2023-11-16 21:27:26adminsetstatus: open -> tentatively ready
2022-12-12 00:00:00admincreate