Merge branch '1.2.0-dev' of https://github.com/geode-sdk/geode into 1.2.0-dev

This commit is contained in:
altalk23 2023-08-27 19:53:45 +03:00
commit e67f59548f

View file

@ -118,9 +118,25 @@ namespace gd {
return m_data.m_length;
}
bool operator<(const gd::string& other) const {
return std::string_view(this->c_str(), this->size()) < std::string_view(other.c_str(), other.size());
}
bool empty() const {
return this->size() == 0;
}
operator bool() const {
return !this->empty();
}
operator std::string() const {
return std::string(this->c_str(), this->size());
}
operator std::string_view() const {
return std::string_view(this->c_str(), this->size());
}
};
template <class T>