Created on 2024-07-30.00:00:00 last changed 1 month ago
Proposed resolution:
This wording is relative to N4986.
Modify [res.on.data.races] as indicated:
-2- A C++ standard library function shall not directly or indirectly access objects ([intro.multithread]) accessible by threads other than the current thread unless the objects are accessed directly or indirectly via the function's
-3- A C++ standard library function shall not directly or indirectly modify objects ([intro.multithread]) accessible by threads other than the current thread unless the objects are accessed directly or indirectly via the function's non-constargumentsparameters, includingthisthe object parameter (if any).argumentsparameters, includingthisthe object parameter (if any). […] -5- A C++ standard library function shall not access objects indirectly accessible via itsargumentsparameters or via elements of its containerargumentsparameters except by invoking functions required by its specification on those container elements.
[ 2025-10-14; Reflector poll ]
Set priority to 3 after reflector poll.
"'non-const parameters' needs to be fixed, this isn't about
top-level const, e.g. std::string& is not a const type."
From PR cplusplus/draft#6748 which was closed as non-editorial.
Currently, [res.on.data.races] is talking about arguments and "including this", but this is not a function argument. Moreover, it seems more appropriate to say that a function accesses some object via a parameter. It might need to be considered whether we should use the more general term "range" instead of "container", which will cover std::span, etc.| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2025-10-14 17:45:42 | admin | set | messages: + msg15157 |
| 2024-08-03 06:54:37 | admin | set | messages: + msg14302 |
| 2024-07-30 00:00:00 | admin | create | |