aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen
diff options
context:
space:
mode:
authorGravatar Benoit Jacob <jacob.benoit.1@gmail.com>2009-11-12 12:49:00 -0500
committerGravatar Benoit Jacob <jacob.benoit.1@gmail.com>2009-11-12 12:49:00 -0500
commit5266a78aca7dd690b61b61210833ddb5c9bf0337 (patch)
treedcf7038c72472a3ecebff4032a7a16ee46bfe953 /Eigen
parent8132ee39089a47efa477599b81eaf571f4af3c45 (diff)
also optionnally initialize by zero after resizing
Diffstat (limited to 'Eigen')
-rw-r--r--Eigen/src/Core/Matrix.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/Eigen/src/Core/Matrix.h b/Eigen/src/Core/Matrix.h
index 3cd7edfd6..4d49911b6 100644
--- a/Eigen/src/Core/Matrix.h
+++ b/Eigen/src/Core/Matrix.h
@@ -260,6 +260,7 @@ class Matrix
&& (MaxColsAtCompileTime == Dynamic || MaxColsAtCompileTime >= cols)
&& (ColsAtCompileTime == Dynamic || ColsAtCompileTime == cols));
m_storage.resize(rows * cols, rows, cols);
+ EIGEN_INITIALIZE_BY_ZERO_IF_THAT_OPTION_IS_ENABLED
}
/** Resizes \c *this to a vector of length \a size
@@ -281,6 +282,7 @@ class Matrix
m_storage.resize(size, 1, size);
else
m_storage.resize(size, size, 1);
+ EIGEN_INITIALIZE_BY_ZERO_IF_THAT_OPTION_IS_ENABLED
}
/** Resizes the matrix, changing only the number of columns. For the parameter of type NoChange_t, just pass the special value \c NoChange