#ifndef PYTHONIC_UTILS_NUMPY_CONVERSION_HPP #define PYTHONIC_UTILS_NUMPY_CONVERSION_HPP #include "pythonic/include/utils/numpy_conversion.hpp" #include "pythonic/utils/numpy_traits.hpp" #if _MSC_VER && !__clang__ #define NUMPY_EXPR_TO_NDARRAY0_IMPL(fname) \ template ::value && \ types::is_array::value, \ E>::type * = nullptr> \ auto fname(E const &expr, Types &&... others) \ { \ return fname(types::ndarray{expr}, \ std::forward(others)...); \ } #else #define NUMPY_EXPR_TO_NDARRAY0_IMPL(fname) \ template \ auto fname(E const &expr, Types &&... others) \ ->typename std::enable_if< \ !types::is_ndarray::value && types::is_array::value, \ decltype(fname( \ types::ndarray{expr}, \ std::forward(others)...))>::type \ { \ return fname(types::ndarray{expr}, \ std::forward(others)...); \ } #endif #endif