From ab95b3fd979bb317fef516f68daa6e01cabd1a33 Mon Sep 17 00:00:00 2001 From: evomarc Date: Mon, 29 Nov 2004 20:49:34 +0000 Subject: [PATCH] Corrected some bugs in eoGeneralXXXBounds (e.g. no const in copy Ctor arguments) Added a default value for the intialization (-infty, +infty) Needs to allow uniform() on unbounded - still pondering --- eo/src/utils/eoIntBounds.h | 4 ++-- eo/src/utils/eoRealBounds.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/eo/src/utils/eoIntBounds.h b/eo/src/utils/eoIntBounds.h index a38253b4..0fbc26b3 100644 --- a/eo/src/utils/eoIntBounds.h +++ b/eo/src/utils/eoIntBounds.h @@ -539,13 +539,13 @@ class eoGeneralIntBounds : public eoIntBounds { public: /** Ctor: from a string, chooses the type of bound */ - eoGeneralIntBounds(std::string _s) + eoGeneralIntBounds(std::string _s = "[-infinity,+infinity]") { repBound = getBoundsFromString(_s); } /** Need a Cpy Ctor because we are allocating memory */ - eoGeneralIntBounds(eoGeneralIntBounds & _b) + eoGeneralIntBounds(const eoGeneralIntBounds & _b) { // replicate the embedded bound (I'm pretty sure there is another // way to do that !!! diff --git a/eo/src/utils/eoRealBounds.h b/eo/src/utils/eoRealBounds.h index fa69e440..552ee038 100644 --- a/eo/src/utils/eoRealBounds.h +++ b/eo/src/utils/eoRealBounds.h @@ -504,13 +504,13 @@ class eoGeneralRealBounds : public eoRealBounds { public: /** Ctor: from a string, chooses the type of bound */ - eoGeneralRealBounds(std::string _s) + eoGeneralRealBounds(std::string _s = "[-infinity,+infinity]") { repBound = getBoundsFromString(_s); } /** Need a Cpy Ctor because we are allocating memory */ - eoGeneralRealBounds(eoGeneralRealBounds & _b) + eoGeneralRealBounds(const eoGeneralRealBounds & _b) { // replicate the embedded bound (I'm pretty sure there is another // way to do that !!!