1380. pair and tuple of references need to better specify move-semantics

Section: 22.3 [pairs] Status: Resolved Submitter: DIN Opened: 2010-08-25 Last modified: 2016-01-28 10:19:27 UTC

Priority: Not Prioritized

View all other issues in [pairs].

View all issues with Resolved status.


Addresses DE-16

Several pair and tuple functions in regard to move operations are incorrectly specified if the member types are references, because the result of a std::move cannot be assigned to lvalue-references. In this context the usage of the requirement sets MoveConstructible and CopyConstructible also doesn't make sense, because non-const lvalue-references cannot satisfy these requirements.

[ Resolution proposed by ballot comment ]

Replace the usage of std::move by that of std::forward and replace MoveConstructible and CopyConstructible requirements by other requirements.

[ 2010-10-24 Daniel adds: ]

Accepting n3140 would solve this issue.

[ 2010-11 Batavia: ]

Resolved by adopting n3140.

Proposed resolution:

See n3140.