/* #ifndef __GNUC__ #include "AMEGIC++/String/MyString.H" #include "ATOOLS/Math/MathTools.H" using namespace AMEGIC; MyString::MyString(const char* str) { if (!str) { len = 0; _string = new char[1]; _string[0] = 0; } else { len = strlen(str); _string = new char[len+1]; strcpy(_string,str); } } MyString::MyString(const MyString& str) { len = str.len; if (!str._string) { len = 0; _string = new char[1]; _string[0] = 0; } else { _string = new char[len+1]; strcpy(_string,str._string); } } MyString::~MyString() { if (len==0) delete _string; else delete[] _string; } MyString& MyString::operator=(const MyString& str) { if (this!=&str) { if (len>0) delete[] _string; if (len==0) delete _string; len = str.length(); _string = new char[len+1]; strcpy(_string,str.c_str()); } return *this; } MyString& MyString::operator+=(const MyString& str) { if (str._string) { if (_string) { MyString tmp(*this); if (len==0) delete _string; else delete[] _string; len += str.len; _string = new char[len+1]; strcpy(_string,tmp._string); strcpy(_string+tmp.len,str._string); } else { len = str.len; _string = new char[len+1]; strcpy(_string,str._string); } } return *this; } MyString& MyString::operator+=(const char* s) { if (_string) { if (s) { MyString tmp(*this); if (len==0) delete _string; else delete[] _string; len += strlen(s); _string = new char[len+1]; strcpy(_string,tmp._string); strcpy(_string+tmp.len,s); } } else { len = strlen(s); _string = new char[len+1]; strcpy(_string,s); } return *this; } ostream& AMEGIC::operator<<(ostream& s, const MyString& str) { return s<len-1) { msg_Error()<<"MyString::Out of Range: "<<_string<<":"<0) { char* help; long int i; help = new char[_len+1]; for (i=pos;i