6 #if __has_feature(cxx_nullptr) && __has_feature(cxx_decltype)
7 # define OS_HAS_NULLPTR 1
10 #if __has_feature(cxx_rvalue_references) || __has_extension(cxx_rvalue_references)
11 # define OS_HAS_RVALUE_REFERENCES 1
16 typedef decltype(nullptr) nullptr_t
;
23 template <class _T
> struct remove_reference
{typedef _T type
;};
24 template <class _T
> struct remove_reference
<_T
&> {typedef _T type
;};
25 template <class _T
> struct remove_reference
<_T
&&> {typedef _T type
;};
26 template <class _T
> using remove_reference_t
= typename remove_reference
<_T
>::type
;
32 template <class _T
> struct remove_const
{typedef _T type
;};
33 template <class _T
> struct remove_const
<const _T
> {typedef _T type
;};
34 template <class _T
> using remove_const_t
= typename remove_const
<_T
>::type
;
41 inline typename remove_reference
<_T
>::type
&&
44 typedef typename
os::remove_reference
<_T
>::type _U
;
45 return static_cast<_U
&&>(_t
);
49 #endif /* _OS_CPP_UTIL_H */