From 25f44266a280df45ed041094a05b096a29c90751 Mon Sep 17 00:00:00 2001 From: Benoit Jacob Date: Sun, 27 Jun 2010 08:44:21 -0400 Subject: [PATCH] fix #146 --- Eigen/src/Core/IO.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Eigen/src/Core/IO.h b/Eigen/src/Core/IO.h index 3fb61300b..7a823d225 100644 --- a/Eigen/src/Core/IO.h +++ b/Eigen/src/Core/IO.h @@ -155,6 +155,12 @@ struct ei_significant_decimals_impl template std::ostream & ei_print_matrix(std::ostream & s, const Derived& _m, const IOFormat& fmt) { + if(_m.size() == 0) + { + s << fmt.matPrefix << fmt.matSuffix; + return s; + } + const typename Derived::Nested m = _m; typedef typename Derived::Scalar Scalar; typedef typename Derived::Index Index;