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.

2999. §[thread.decaycopy] issue

Section: 16.3.3.2 [expos.only.entity] Status: Resolved Submitter: Marshall Clow Opened: 2017-07-11 Last modified: 2023-02-07

Priority: 3

View all other issues in [expos.only.entity].

View all issues with Resolved status.

Discussion:

[thread.decaycopy] says:

In several places in this Clause the operation DECAY_COPY(x) is used. All such uses mean call the function decay_copy(x) and use the result, where decay_copy is defined as follows:

but decay_copy is not defined in any synopsis.

The Ranges TS has a similar use of DECAY_COPY, except that theirs is also constexpr and noexcept.

We should mark the function decay_copy as "exposition only" and constexpr and noexcept.

[2017-07-16, Daniel comments]

Currently there exists no proper way to mark decay_copy as conditionally noexcept as explained in N3255 section "Adding to the Standard". This is also slighly related to the request to add an is_nothrow_convertible trait, as requested by LWG 2040(i).

[ 2017-11-01 P3 as result of c++std-lib online vote. ]

[2019-03-22; Daniel comments]

Starting with N4800 have now a constexpr and conditionally noexcept decay-copy in the working draft ( [expos.only.func]). The pre-condition for that specification helper became possible by adoption of P0758R1, which introduced the missing is_nothrow_convertible trait.

[2020-05-03; Reflector discussions]

Resolved by editorial action starting with N4800.

Rationale:

Resolved by editorial creation of decay-copy after acceptance of P0758R1.

Proposed resolution: