Add constructors from std::string/const char * to rdctype::str

This commit is contained in:
baldurk
2016-08-03 12:25:50 +02:00
parent 2bb34bffc6
commit 056d3d01ee
+2
View File
@@ -144,6 +144,8 @@ struct str : public rdctype::array<char>
str() : rdctype::array<char>() {}
str(const str &o) : rdctype::array<char>() { *this = o; }
str(const std::string &o) : rdctype::array<char>() { *this = o; }
str(const char *const o) : rdctype::array<char>() { *this = o; }
str &operator=(const str &o)
{
// do nothing if we're self-assigning