This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 110b. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.

2023-01-15


876. Type references in rvalue reference deduction specification

Section: 13.10.3.2  [temp.deduct.call]     Status: CD2     Submitter: Steve Adamczyk     Date: 20 April, 2009

[Voted into WP at October, 2009 meeting.]

13.10.3.2 [temp.deduct.call] paragraph 3 says,

If P is of the form T&&, where T is a template parameter, and the argument is an lvalue, the type A& is used in place of A for type deduction.

The type references in that sentence are inconsistent with the normal usage in the Standard; they should instead refer to “an rvalue reference to a cv-unqualified template parameter” and “lvalue reference to A.”

Proposed resolution (July, 2009):

Change 13.10.3.2 [temp.deduct.call] paragraph 3 as follows:

If P is a cv-qualified type, the top level cv-qualifiers of P's type are ignored for type deduction. If P is a reference type, the type referred to by P is used for type deduction. If P is of the form T&&, where T is a template parameter, an rvalue reference to a cv-unqualified template parameter and the argument is an lvalue, the type A& “lvalue reference to A is used in place of A for type deduction.