Skip to content
Snippets Groups Projects
Unverified Commit 02fe1716 authored by Justin Carpentier's avatar Justin Carpentier
Browse files

test/sparse: fix bug

parent b64ee3c4
No related branches found
No related tags found
No related merge requests found
......@@ -26,7 +26,8 @@ Eigen::SparseMatrix<Scalar, Options> matrix1x1(const Scalar& value) {
template <typename Scalar, int Options>
Eigen::SparseMatrix<Scalar, Options> diagonal(
const Eigen::Ref<Eigen::Matrix<Scalar, Eigen::Dynamic, 1> >& diag_values) {
const Eigen::Ref<const Eigen::Matrix<Scalar, Eigen::Dynamic, 1> >&
diag_values) {
typedef Eigen::SparseMatrix<Scalar, Options> ReturnType;
ReturnType mat(diag_values.size(), diag_values.size());
for (Eigen::Index k = 0; k < diag_values.size(); ++k)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment