add_rvalue_reference.hpp
Go to the documentation of this file.
1 // add_rvalue_reference.hpp ---------------------------------------------------------//
2 
3 // Copyright 2010 Vicente J. Botet Escriba
4 
5 // Distributed under the Boost Software License, Version 1.0.
6 // See http://www.boost.org/LICENSE_1_0.txt
7 
8 #ifndef BOOST_TYPE_TRAITS_EXT_ADD_RVALUE_REFERENCE__HPP
9 #define BOOST_TYPE_TRAITS_EXT_ADD_RVALUE_REFERENCE__HPP
10 
11 #include <boost/config.hpp>
12 
13 //----------------------------------------------------------------------------//
14 
17 
18 //----------------------------------------------------------------------------//
19 // //
20 // C++03 implementation of //
21 // 20.9.7.2 Reference modifications [meta.trans.ref] //
22 // Written by Vicente J. Botet Escriba //
23 // //
24 // If T names an object or function type then the member typedef type
25 // shall name T&&; otherwise, type shall name T. [ Note: This rule reflects
26 // the semantics of reference collapsing. For example, when a type T names
27 // a type T1&, the type add_rvalue_reference<T>::type is not an rvalue
28 // reference. -end note ]
29 //----------------------------------------------------------------------------//
30 
31 namespace boost {
32 
33 namespace type_traits_detail {
34 
35  template <typename T, bool b>
37  { typedef T type; };
38 
39 #if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES)
40  template <typename T>
42  {
43  typedef T&& type;
44  };
45 #endif
46 
47  template <typename T>
49  {
51  <T, (is_void<T>::value == false && is_reference<T>::value == false) >::type type;
52  };
53 
54 }
55 
56 template <class T> struct add_rvalue_reference
57 {
59 };
60 
61 #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES)
62 
63  template <class T> using add_rvalue_reference_t = typename add_rvalue_reference<T>::type;
64 
65 #endif
66 
67 } // namespace boost
68 
69 #endif // BOOST_TYPE_TRAITS_EXT_ADD_RVALUE_REFERENCE__HPP
70 
BOOST_MOVE_USE_STANDARD_LIBRARY_MOVE.
boost::type_traits_detail::add_rvalue_reference_helper< T,(is_void< T >::value==false &&is_reference< T >::value==false) >::type type
typename add_rvalue_reference< T >::type add_rvalue_reference_t
boost::type_traits_detail::add_rvalue_reference_imp< T >::type type


librealsense2
Author(s): Sergey Dorodnicov , Doron Hirshberg , Mark Horn , Reagan Lopez , Itay Carpis
autogenerated on Mon May 3 2021 02:45:06