Skip to content

Commit 2e04f69

Browse files
committed
Fixes for Eigen 3.3
Cf. #35
1 parent 4cec44e commit 2e04f69

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/tnlp.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ namespace roboptim
6464
constraintJacobians_.push_back ((*it)->jacobian (x));
6565
differentiableFunction_t::jacobian_t& jac = constraintJacobians_.back ();
6666
jac.makeCompressed ();
67-
nnz_jac_g += jac.nonZeros ();
67+
nnz_jac_g += static_cast<Index> (jac.nonZeros ());
6868
}
6969

7070
nnz_h_lag = 0; // unused
@@ -129,7 +129,7 @@ namespace roboptim
129129
coefficients.push_back
130130
(triplet_t (row, col, it.value ()));
131131
}
132-
idx += (*it)->outputSize ();
132+
idx += static_cast<int> ((*it)->outputSize ());
133133
}
134134

135135
jacobianBuf_->setFromTriplets
@@ -143,7 +143,7 @@ namespace roboptim
143143
for (differentiableFunction_t::jacobian_t::InnerIterator it (*jacobianBuf_, k);
144144
it; ++it)
145145
{
146-
iRow[idx] = it.row (), jCol[idx] = it.col ();
146+
iRow[idx] = static_cast<Index> (it.row ()), jCol[idx] = static_cast<Index> (it.col ());
147147
++idx;
148148
}
149149

0 commit comments

Comments
 (0)