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

918. Swap for tuple needs to be conceptualized

Section: 22.4.4.3 [tuple.swap] Status: NAD Concepts Submitter: Daniel Krügler Opened: 2008-10-04 Last modified: 2016-01-28

Priority: Not Prioritized

View all issues with NAD Concepts status.

Discussion:

Issue 522 was accepted after tuple had been conceptualized, therefore this step needs to be completed.

[ Post Summit Daniel adds ]

This is now NAD Editorial (addressed by N2844) except for item 3 in the proposed wording.

[ 2009-05-01 Daniel adds: ]

As of the recent WP (N2857), this issue is now completely covered by editorial changes (including the third bullet), therefore I unconditionally recommend NAD.

[ Batavia (2009-05): ]

We observed that all the proposed changes have already been applied to the Working Draft, rendering this issue moot.

Move to NAD.

Proposed resolution:

  1. In both 22.4.1 [tuple.general]/2 and 22.4.12 [tuple.special] change

    template <class Swappable... Types>
    void swap(tuple<Types...>& x, tuple<Types...>& y);
    
  2. In 22.4.4 [tuple.tuple], class tuple definition and in 22.4.4.3 [tuple.swap], change

    requires Swappable<Types>...void swap(tuple&);
    
  3. In 22.4.4.3 [tuple.swap] remove the current requires-clause, which says:

    Requires: Each type in Types shall be Swappable