1 #ifndef PYTHONIC_NUMPY_NDARRAY_ASTYPE_HPP 2 #define PYTHONIC_NUMPY_NDARRAY_ASTYPE_HPP 3 4 #include "pythonic/include/numpy/ndarray/astype.hpp" 5 #include "pythonic/numpy/asarray.hpp" 6 7 PYTHONIC_NS_BEGIN 8 9 namespace numpy 10 { 11 namespace ndarray 12 { 13 14 template <class E, class dtype> astype(E && e,dtype d)15 auto astype(E &&e, dtype d) -> decltype(asarray(std::forward<E>(e), d)) 16 { 17 return asarray(std::forward<E>(e), d); 18 } 19 } 20 } 21 PYTHONIC_NS_END 22 23 #endif 24