diff options
author | Gael Guennebaud <g.gael@free.fr> | 2012-10-03 21:58:14 +0200 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2012-10-03 21:58:14 +0200 |
commit | a67eea05c167e69f5e82410941d8645764e45038 (patch) | |
tree | 08dec04b970cae10a43198f9c690fa9bd6921eee /Eigen/src/Core/CommaInitializer.h | |
parent | cfa8032ffb2337ccc4e1b14c6c244fd75ea0fa95 (diff) |
fix comma initializer when inserting empty matrices
Diffstat (limited to 'Eigen/src/Core/CommaInitializer.h')
-rw-r--r-- | Eigen/src/Core/CommaInitializer.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Eigen/src/Core/CommaInitializer.h b/Eigen/src/Core/CommaInitializer.h index 4adce6414..f20c1774c 100644 --- a/Eigen/src/Core/CommaInitializer.h +++ b/Eigen/src/Core/CommaInitializer.h @@ -65,6 +65,8 @@ struct CommaInitializer template<typename OtherDerived> CommaInitializer& operator,(const DenseBase<OtherDerived>& other) { + if(other.cols()==0 || other.rows()==0) + return *this; if (m_col==m_xpr.cols()) { m_row+=m_currentBlockRows; |