diff --git a/CHANGELOG.md b/CHANGELOG.md index 3fbb059e..686116d3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). ### Fixed - Remove CMake CMP0167 warnings ([#487](https://github.com/stack-of-tasks/eigenpy/pull/487)) +- Fix compilation error on armhf ([#488](https://github.com/stack-of-tasks/eigenpy/pull/488)) ## [3.7.0] - 2024-06-11 diff --git a/include/eigenpy/numpy.hpp b/include/eigenpy/numpy.hpp index 3786b091..1d7b68f7 100644 --- a/include/eigenpy/numpy.hpp +++ b/include/eigenpy/numpy.hpp @@ -55,7 +55,7 @@ void EIGENPY_DLLAPI import_numpy(); int EIGENPY_DLLAPI PyArray_TypeNum(PyTypeObject* type); // By default, the Scalar is considered as a Python object -template +template struct NumpyEquivalentType { enum { type_code = NPY_USERDEF }; }; @@ -139,12 +139,19 @@ struct NumpyEquivalentType { // See https://github.com/stack-of-tasks/eigenpy/pull/455 #if defined __linux__ -template <> -struct NumpyEquivalentType { +#include + +template +struct NumpyEquivalentType< + Scalar, std::enable_if_t::value && + std::is_same::value> > { enum { type_code = NPY_LONGLONG }; }; -template <> -struct NumpyEquivalentType { +template +struct NumpyEquivalentType< + Scalar, + std::enable_if_t::value && + std::is_same::value> > { enum { type_code = NPY_ULONGLONG }; };