Pass div_ceil arguments by value.

This commit is contained in:
Antonio Sánchez 2023-10-17 18:46:19 +00:00 committed by Rasmus Munk Larsen
parent d9839718aa
commit 0c9526912c

View File

@ -1345,7 +1345,7 @@ double ceil(const double &x) { return ::ceil(x); }
// T is assumed to be an integer type with a>=0, and b>0
template<typename T>
EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE EIGEN_CONSTEXPR
T div_ceil(const T &a, const T &b)
T div_ceil(T a, T b)
{
EIGEN_STATIC_ASSERT((NumTraits<T>::IsInteger), THIS FUNCTION IS FOR INTEGER TYPES)
eigen_assert(a >= 0);