mirror of
https://github.com/boostorg/fusion.git
synced 2025-07-21 16:22:45 +02:00
Support move for make_vector.
This commit is contained in:
@ -19,6 +19,8 @@
|
|||||||
///////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
#include <boost/fusion/support/detail/as_fusion_element.hpp>
|
#include <boost/fusion/support/detail/as_fusion_element.hpp>
|
||||||
|
#include <boost/type_traits/remove_reference.hpp>
|
||||||
|
#include <utility>
|
||||||
|
|
||||||
namespace boost { namespace fusion
|
namespace boost { namespace fusion
|
||||||
{
|
{
|
||||||
@ -47,7 +49,9 @@ namespace boost { namespace fusion
|
|||||||
typedef
|
typedef
|
||||||
typename trim_void<
|
typename trim_void<
|
||||||
vector<>
|
vector<>
|
||||||
, typename detail::as_fusion_element<T>::type...
|
, typename detail::as_fusion_element<
|
||||||
|
typename remove_reference<T>::type
|
||||||
|
>::type...
|
||||||
>::type
|
>::type
|
||||||
type;
|
type;
|
||||||
};
|
};
|
||||||
@ -56,9 +60,9 @@ namespace boost { namespace fusion
|
|||||||
template <typename ...T>
|
template <typename ...T>
|
||||||
BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
|
BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
|
||||||
inline typename result_of::make_vector<T...>::type
|
inline typename result_of::make_vector<T...>::type
|
||||||
make_vector(T const&... arg)
|
make_vector(T&&... arg)
|
||||||
{
|
{
|
||||||
return typename result_of::make_vector<T...>::type(arg...);
|
return typename result_of::make_vector<T...>::type(std::forward<T>(arg)...);
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user