File indexing completed on 2025-09-13 08:50:21
0001 #ifndef BOOST_QVM_GEN_VEC_ASSIGN3_HPP_INCLUDED
0002 #define BOOST_QVM_GEN_VEC_ASSIGN3_HPP_INCLUDED
0003
0004
0005
0006
0007
0008
0009 #include <boost/qvm/config.hpp>
0010 #include <boost/qvm/enable_if.hpp>
0011 #include <boost/qvm/vec_traits.hpp>
0012
0013 namespace boost { namespace qvm {
0014
0015 template <class A,class B>
0016 BOOST_QVM_CONSTEXPR BOOST_QVM_INLINE_OPERATIONS
0017 typename enable_if_c<
0018 vec_traits<A>::dim==3 && vec_traits<B>::dim==3,
0019 A &>::type
0020 assign( A & a, B const & b )
0021 {
0022 write_vec_element<0>(a,vec_traits<B>::template read_element<0>(b));
0023 write_vec_element<1>(a,vec_traits<B>::template read_element<1>(b));
0024 write_vec_element<2>(a,vec_traits<B>::template read_element<2>(b));
0025 return a;
0026 }
0027
0028 namespace
0029 sfinae
0030 {
0031 using ::boost::qvm::assign;
0032 }
0033
0034 namespace
0035 qvm_detail
0036 {
0037 template <int D>
0038 struct assign_vv_defined;
0039
0040 template <>
0041 struct
0042 assign_vv_defined<3>
0043 {
0044 static bool const value=true;
0045 };
0046 }
0047
0048 } }
0049
0050 #endif