Verified Commit 66e39351 authored by Justin Carpentier's avatar Justin Carpentier
Browse files

core: set default type to be NPY_USERDEF

parent 6a9a45cb
......@@ -18,7 +18,7 @@ namespace eigenpy
namespace bp = boost::python;
// By default, the Scalar is considered as a Python object
template <typename Scalar> struct NumpyEquivalentType { enum { type_code = NPY_OBJECT };};
template <typename Scalar> struct NumpyEquivalentType { enum { type_code = NPY_USERDEF };};
template <> struct NumpyEquivalentType<float> { enum { type_code = NPY_FLOAT };};
template <> struct NumpyEquivalentType< std::complex<float> > { enum { type_code = NPY_CFLOAT };};
......@@ -33,7 +33,7 @@ namespace eigenpy
template<typename Scalar>
bool isNumpyNativeType()
{
if(NumpyEquivalentType<Scalar>::type_code == NPY_OBJECT)
if(NumpyEquivalentType<Scalar>::type_code == NPY_USERDEF)
return false;
return true;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment