From f4b71dffadfec840c4bbfd29f7471a6ae0659d5d Mon Sep 17 00:00:00 2001 From: Johann Dreo Date: Thu, 13 Jun 2013 14:48:00 +0200 Subject: [PATCH] Add a warning when computing stat in empty pop --- eo/src/utils/eoStat.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/eo/src/utils/eoStat.h b/eo/src/utils/eoStat.h index fd26ec228..ccf3c4137 100644 --- a/eo/src/utils/eoStat.h +++ b/eo/src/utils/eoStat.h @@ -40,6 +40,7 @@ Contact: http://eodev.sourceforge.net #include #include //#include +#include /** @defgroup Stats Statistics computation * @@ -485,7 +486,8 @@ public: virtual void operator()( const eoPop & _pop ) { if( _pop.size() == 0 ) { - // how to implement value() = 0 ? + //FIXME how to implement value() = 0 ? + eo::log << eo::warnings << "Called " << className() << " on an empty pop, value unchanged" << std::endl; } else { eoPop pop = _pop;