diff --git a/include/boost/numeric/ublas/detail/concepts.hpp b/include/boost/numeric/ublas/detail/concepts.hpp index 0bf2ba8a..ce99744b 100644 --- a/include/boost/numeric/ublas/detail/concepts.hpp +++ b/include/boost/numeric/ublas/detail/concepts.hpp @@ -638,61 +638,73 @@ namespace boost { namespace numeric { namespace ublas { T ZeroElement (T); template<> + BOOST_UBLAS_INLINE float ZeroElement (float) { return 0.f; } template<> + BOOST_UBLAS_INLINE double ZeroElement (double) { return 0.; } template<> + BOOST_UBLAS_INLINE vector ZeroElement (vector) { return zero_vector (); } template<> + BOOST_UBLAS_INLINE vector ZeroElement (vector) { return zero_vector (); } template<> + BOOST_UBLAS_INLINE matrix ZeroElement (matrix) { return zero_matrix (); } template<> + BOOST_UBLAS_INLINE matrix ZeroElement (matrix) { return zero_matrix (); } template<> + BOOST_UBLAS_INLINE std::complex ZeroElement (std::complex) { return std::complex (0.f); } template<> + BOOST_UBLAS_INLINE std::complex ZeroElement (std::complex) { return std::complex (0.); } template<> + BOOST_UBLAS_INLINE vector > ZeroElement (vector >) { return zero_vector > (); } template<> + BOOST_UBLAS_INLINE vector > ZeroElement (vector >) { return zero_vector > (); } template<> + BOOST_UBLAS_INLINE matrix > ZeroElement (matrix >) { return zero_matrix > (); } template<> + BOOST_UBLAS_INLINE matrix > ZeroElement (matrix >) { return zero_matrix > (); @@ -702,41 +714,49 @@ namespace boost { namespace numeric { namespace ublas { T OneElement (T); template<> + BOOST_UBLAS_INLINE float OneElement (float) { return 1.f; } template<> + BOOST_UBLAS_INLINE double OneElement (double) { return 1.; } template<> + BOOST_UBLAS_INLINE matrix OneElement (matrix) { return identity_matrix (); } template<> + BOOST_UBLAS_INLINE matrix OneElement (matrix) { return identity_matrix (); } template<> + BOOST_UBLAS_INLINE std::complex OneElement (std::complex) { return std::complex (1.f); } template<> + BOOST_UBLAS_INLINE std::complex OneElement (std::complex) { return std::complex (1.); } template<> + BOOST_UBLAS_INLINE matrix > OneElement (matrix >) { return identity_matrix > (); } template<> + BOOST_UBLAS_INLINE matrix > OneElement (matrix >) { return identity_matrix > (); @@ -888,6 +908,7 @@ namespace boost { namespace numeric { namespace ublas { } }; + BOOST_UBLAS_INLINE void concept_checks () { // Allow tests to be group to keep down compiler storage requirement