2 Copyright 2010 John Maddock.
3 Distributed under the Boost Software License, Version 1.0.
4 (See accompanying file LICENSE_1_0.txt or copy at
5 http://www.boost.org/LICENSE_1_0.txt).
8 [section:add_rvalue_reference add_rvalue_reference]
11 struct add_rvalue_reference
16 __type If `T` names an object or function type then the member typedef type
17 shall name `T&&`; otherwise, type shall name `T`. ['\[Note: This rule reflects
18 the semantics of reference collapsing. For example, when a type `T` names
19 a type U&, the type `add_rvalue_reference<T>::type` is not an rvalue
20 reference. -end note\]].
24 __header ` #include <boost/type_traits/add_rvalue_reference.hpp>` or ` #include <boost/type_traits.hpp>`
28 [ [Expression] [Result Type]]
30 [[`add_rvalue_reference<int>::type`][`int&&`]]
32 [[`add_rvalue_reference<int const&>::type`] [`int const&`]]
34 [[`add_rvalue_reference<int*>::type`] [`int*&&`]]
36 [[`add_rvalue_reference<int*&>::type`] [`int*&`]]
38 [[`add_rvalue_reference<int&&>::type`][`int&&`]]
40 [[`add_rvalue_reference<void>::type`][`void`]]
44 __compat In the absence of rvalue-reference support this trait has no effect.