This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 112e. See for the official list.


2472. Value categories in await-expressions

Section:  [expr.await]     Status: NAD     Submitter: Daveed Vandevoorde     Date: 2021-01-18

According to [expr.await] bullets 3.3 and 3.4,

Evaluation of an await-expression involves the following auxiliary types, expressions, and objects:

However, the temporary materialization conversion produces an xvalue, not an lvalue. Should e be a glvalue instead of an lvalue?

Rationale (February, 2021):

The specification is as intended; o is converted to an lvalue if it is an xvalue result of the temporary materialization conversion. e is used in both bullets 3.7 and 3.8; if it were an xvalue instead of an lvalue, the call to await_suspend could steal e's resources and leave the call to await_resume with a defunct object, which would be undesirable.