From 40fb64a5aaecb0844fd427c65e3da6dab2efba44 Mon Sep 17 00:00:00 2001 From: nojhan Date: Tue, 24 Mar 2020 16:37:30 +0100 Subject: [PATCH] feat: add a dummy continue, always returning true. Useful in do_make* when no continue may be instanciated. --- eo/src/eoContinue.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/eo/src/eoContinue.h b/eo/src/eoContinue.h index 429ea58b7..cdf9ea432 100644 --- a/eo/src/eoContinue.h +++ b/eo/src/eoContinue.h @@ -67,6 +67,17 @@ public: } }; +/** A continue that always return true. + * + * @ingroup Continuators + */ +template< class EOT > +class eoDummyContinue : public eoContinue< EOT > +{ + public: + bool operator()(const eoPop&) {return true;} +}; + /** * Termination condition with a count condition (totalGenerations). This continuator contains * a count of cycles, which can be retrieved or set.