This page is a snapshot from the LWG issues list, see the Library Active Issues List for more information and the meaning of Resolved status.
Section: 23 [utilities], 23.19 [execpol] Status: Resolved Submitter: Great Britain Opened: 2017-02-03 Last modified: 2017-05-31
Priority: Not Prioritized
View all other issues in [utilities].
View all issues with Resolved status.
Discussion:Addresses GB 28
The C++ standard library provides many constexpr global variables. These all create the risk of ODR violations for innocent user code. This is especially bad for the new ExecutionPolicy algorithms, since their constants are always passed by reference, so any use of those algorithms from an inline function results in an ODR violation.
This can be avoided by marking the globals as inline.
Proposed change: Add inline specifier to: bind placeholders _1, _2, ..., nullopt, piecewise_construct, allocator_arg, ignore, seq, par, par_unseq in <execution>
[2017-02-03, Marshall notes]
See also FI 9 (LWG 2888).
[2017-02-25, Daniel comments]
There will be the paper p0607r0 provided for the Kona meeting that solves this issue.
Resolved by p0607r0.