We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 44b56bb commit 283f2b8Copy full SHA for 283f2b8
1 file changed
include/xtensor/xrepeat.hpp
@@ -263,7 +263,9 @@ namespace xt
263
, m_shape(e.shape())
264
{
265
using shape_value_type = typename shape_type::value_type;
266
- m_shape[axis] = static_cast<shape_value_type>(std::accumulate(m_repeats.begin(), m_repeats.end(), 0));
+ m_shape[axis] = static_cast<shape_value_type>(
267
+ std::accumulate(m_repeats.begin(), m_repeats.end(), shape_value_type(0))
268
+ );
269
}
270
271
/**
0 commit comments