Silent maybe-uninitialized warnings by gcc

This commit is contained in:
Gael Guennebaud 2019-01-15 16:53:15 +01:00
parent 6ec6bf0b0d
commit 2c2c114995

View File

@ -137,6 +137,8 @@ namespace internal {
template <typename Derived>
struct coeff_visitor
{
// default initialization to avoid countless invalid maybe-uninitialized warnings by gcc
coeff_visitor() : row(-1), col(-1), res(0) {}
typedef typename Derived::Scalar Scalar;
Index row, col;
Scalar res;