Backport "disambiguate overloads for empty index list" to 3.4 branch

This commit is contained in:
Silvio Traversaro 2023-11-10 04:03:11 +00:00 committed by Antonio Sánchez
parent bae907b8f6
commit fc5575264f

View File

@ -261,7 +261,7 @@ template <typename Idx> struct IndexPair {
#ifdef EIGEN_HAS_SFINAE #ifdef EIGEN_HAS_SFINAE
namespace internal { namespace internal {
template<typename IndexType, typename Index, Index... Is> template<typename IndexType, typename Index, Index First, Index... Is>
EIGEN_CONSTEXPR EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE EIGEN_CONSTEXPR EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE
array<Index, 1 + sizeof...(Is)> customIndices2Array(IndexType& idx, numeric_list<Index, First, Is...>) { array<Index, 1 + sizeof...(Is)> customIndices2Array(IndexType& idx, numeric_list<Index, First, Is...>) {
return { static_cast<Index>(idx[First]), static_cast<Index>(idx[Is])... }; return { static_cast<Index>(idx[First]), static_cast<Index>(idx[Is])... };