Title
type-trait decay incompletely specified
Status
cd1
Section
[meta.trans.other]
Submitter
Thorsten Ottosen

Created on 2007-07-08.00:00:00 last changed 172 months ago

Messages

Date: 2010-10-21.18:28:33

Proposed resolution:

In [meta.trans.other] change the last sentence:

Otherwise the member typedef type equals remove_cv<U>::type.

In [tuple.creation]/1 change:

where each Vi in VTypes is X& if, for the corresponding type Ti in Types, remove_cv<remove_reference<Ti>::type>::type equals reference_wrapper<X>, otherwise Vi is decay<Ti>::type. Let Ui be decay<Ti>::type for each Ti in Types. Then each Vi in VTypes is X& if Ui equals reference_wrapper<X>, otherwise Vi is Ui.

Date: 2007-07-08.00:00:00

The current working draft has a type-trait decay in [meta.trans.other].

Its use is to turn C++03 pass-by-value parameters into efficient C++0x pass-by-rvalue-reference parameters. However, the current definition introduces an incompatible change where the cv-qualification of the parameter type is retained. The deduced type should loose such cv-qualification, as pass-by-value does.

History
Date User Action Args
2010-10-21 18:28:33adminsetmessages: + msg3495
2007-07-08 00:00:00admincreate