diff --git a/include/wx/string.h b/include/wx/string.h index 4fb1ec16cc..1edfd388ef 100644 --- a/include/wx/string.h +++ b/include/wx/string.h @@ -1298,8 +1298,6 @@ public: wxString Clone() const { - // make a deep copy of the string, i.e. the returned string will have - // ref count = 1 with refcounted implementation return wxString::FromImpl(wxStringImpl(m_impl.c_str(), m_impl.length())); } diff --git a/interface/wx/string.h b/interface/wx/string.h index c487553b2a..6a9c82716b 100644 --- a/interface/wx/string.h +++ b/interface/wx/string.h @@ -1497,14 +1497,12 @@ public: bool Shrink(); /** - Returns a deep copy of the string. + Returns a copy of the string. - That is, the returned string is guaranteed to not share data with this - string when using reference-counted wxString implementation. - - This method is primarily useful for passing strings between threads - (because wxString is not thread-safe). Unlike creating a copy using - @c wxString(c_str()), Clone() handles embedded NULs correctly. + This method is obsolete as wxString doesn't use reference-counted + implementation any longer and so all string copies are deep and + assignment operator or copy constructor can be used instead of this + function. @since 2.9.0 */