From: eap Date: Tue, 3 Mar 2009 09:00:32 +0000 (+0000) Subject: make same as in V5_1_main X-Git-Tag: V4_1_5rc1~27 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d45660bd010db294db4f6070cfbecfdd2ebaff3e;p=modules%2Fsmesh.git make same as in V5_1_main + operator char*() const { + return (char*)c_str(); + } --- diff --git a/src/SMESH/SMESH_Comment.hxx b/src/SMESH/SMESH_Comment.hxx index d7173cf82..d1d32b9e6 100644 --- a/src/SMESH/SMESH_Comment.hxx +++ b/src/SMESH/SMESH_Comment.hxx @@ -32,34 +32,40 @@ # include # include +using namespace std; + /*! * \brief Class to generate string from any type */ -class SMESH_Comment : public std::string +class SMESH_Comment : public string { - std::ostringstream _s ; + ostringstream _s ; public : - SMESH_Comment(): std::string("") {} + SMESH_Comment():string("") {} - SMESH_Comment(const SMESH_Comment& c): std::string() { + SMESH_Comment(const SMESH_Comment& c):string() { _s << c.c_str() ; - this->std::string::operator=( _s.str() ); + this->string::operator=( _s.str() ); } template SMESH_Comment( const T &anything ) { _s << anything ; - this->std::string::operator=( _s.str() ); + this->string::operator=( _s.str() ); } template SMESH_Comment & operator<<( const T &anything ) { _s << anything ; - this->std::string::operator=( _s.str() ); + this->string::operator=( _s.str() ); return *this ; } + + operator char*() const { + return (char*)c_str(); + } };