Created on 2024-07-30.00:00:00 last changed 4 months 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.
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 |
2024-08-03 06:54:37 | admin | set | messages: + msg14302 |
2024-07-30 00:00:00 | admin | create |