From a2e690cf5ae973a5f2195414197ecb3c6d39f551 Mon Sep 17 00:00:00 2001 From: randomdan Date: Fri, 29 Jul 2011 16:00:24 +0000 Subject: Work around old compiler bug by fully qualifying function call to not get mixed up with a class in ns std --- project2/variableConvert.cpp | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/project2/variableConvert.cpp b/project2/variableConvert.cpp index 0f69a52..b144175 100644 --- a/project2/variableConvert.cpp +++ b/project2/variableConvert.cpp @@ -24,7 +24,7 @@ template const T * set(const VariableType * var, const T * t) { - return set(var, t, deleter); + return ::set(var, t, deleter); } SimpleMessageException(InvalidConversionTo); @@ -41,17 +41,17 @@ class ConvertVisitorGlibUstring : public boost::static_visitor const Glib::ustring & operator()(const T & r) const { - return *set(var, new Glib::ustring(boost::lexical_cast(r))); + return *::set(var, new Glib::ustring(boost::lexical_cast(r))); } private: const VariableType * var; @@ -62,17 +62,17 @@ class ConvertVisitorStdString : public boost::static_visitor const std::string & operator()(const T & r) const { - return *set(var, new std::string(boost::lexical_cast(r))); + return *::set(var, new std::string(boost::lexical_cast(r))); } private: const VariableType * var; @@ -83,17 +83,17 @@ class ConvertVisitorCharStar : public boost::static_visitor { ConvertVisitorCharStar(const VariableType * v) : var(v) { } const char * operator()(const Glib::ustring & r) const { - return set(var, &r, NULL)->c_str(); + return ::set(var, &r, NULL)->c_str(); } const char * operator()(const boost::posix_time::ptime & r) const { - return set(var, new std::string(boost::posix_time::to_iso_extended_string(r)))->c_str(); + return ::set(var, new std::string(boost::posix_time::to_iso_extended_string(r)))->c_str(); } const char * operator()(const Null &) const { - return set(var, NULL, NULL); + return ::set(var, NULL, NULL); } template const char * operator()(const T & r) const { - return set(var, new std::string(boost::lexical_cast(r)))->c_str(); + return ::set(var, new std::string(boost::lexical_cast(r)))->c_str(); } private: const VariableType * var; @@ -108,14 +108,14 @@ class ConvertVisitorUCharStar : public boost::static_visitor( - set(var, new std::string(boost::posix_time::to_iso_extended_string(r)))->c_str()); + ::set(var, new std::string(boost::posix_time::to_iso_extended_string(r)))->c_str()); } const unsigned char * operator()(const Null &) const { - return set(var, NULL, NULL); + return ::set(var, NULL, NULL); } template const unsigned char * operator()(const T & r) const { - return set(var, new std::basic_string(boost::lexical_cast >(r)))->c_str(); + return ::set(var, new std::basic_string(boost::lexical_cast >(r)))->c_str(); } private: const VariableType * var; @@ -148,7 +148,7 @@ class ConvertVisitorDateTime : public boost::static_visitor); + return *::set(var, new boost::posix_time::ptime(boost::posix_time::time_from_string(r)), deleter); } const boost::posix_time::ptime & operator()(const boost::posix_time::ptime & r) const { return r; -- cgit v1.2.3