This page is a snapshot from the LWG issues list, see the Library Active Issues List for more information and the meaning of C++20 status.

3202. P0318R1 was supposed to be revised

Section: 22.10.2 [functional.syn] Status: C++20 Submitter: Jonathan Wakely Opened: 2019-04-23 Last modified: 2021-02-25

Priority: 0

View all issues with C++20 status.


P0318R1 was discussed in Batavia and the requested changes were made in D0318R2. In San Diego the R1 paper was voted into the WP, despite not having the requested changes. There were also changes to D0318R2 suggested on the reflector, which are incorporated below.

[2019-04-30 Priority to 0 and Status to Tentatively Ready after six positive votes on the reflector.]

Proposed resolution:

This wording is relative to N4810.

  1. Modify 22.10.2 [functional.syn], header <functional> synopsis, as indicated:

    template<class T> struct unwrap_reference;
    template<class T> using unwrap_reference_t = typename unwrap_reference<T>::type;
    template<class T> struct unwrap_ref_decay : unwrap_reference<decay_t<T>> {};
    template<class T> using unwrap_ref_decay_t = typename unwrap_ref_decay<T>::type;
  2. Modify 99 [refwrap.unwrapref] as indicated:

    template<class T>
      struct unwrap_reference;

    -1- If T is a specialization […]

    template<class T>
      struct unwrap_ref_decay;

    -?- The member typedef type of unwrap_ref_decay<T> denotes the type unwrap_reference_t<decay_t<T>>.