This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 121a. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.

2026-11-19


3242. Rephrase sentence to avoid "shall"

Section: 7.6.19  [expr.assign]     Status: ready     Submitter: ISO/CS     Date: 2026-10-31

C++26 DIS comment **-066

Subclause 7.6.19 [expr.assign] paragraph 7 uses "shall" twice in connection with undefined behavior, which is not in harmony with the rest of the core language phraseology.

Possible resolution [SUPERSEDED]:

Change in 7.6.19 [expr.assign] paragraph 7 as follows:

If the value being stored in an object is read via another object that overlaps in any way the storage of the first object, then the behavior is undefined unless the overlap shall be is exact and the two objects shall have the same type, otherwise the behavior is undefined.

Proposed resolution (approved by CWG 2026-11-19):

Change in 7.6.19 [expr.assign] paragraph 7 as follows:

If the value being stored in an object is read via another object that overlaps in any way the storage of the first object, then and otherwise the behavior is undefined.