Use C++11 default copy ctor for wxUniCharRef
It's a little simpler, and still suppresses -Wdeprecated-copy warnings
This commit is contained in:
@@ -267,10 +267,8 @@ public:
|
|||||||
wxUniCharRef& operator=(const wxUniCharRef& c)
|
wxUniCharRef& operator=(const wxUniCharRef& c)
|
||||||
{ if (&c != this) *this = c.UniChar(); return *this; }
|
{ if (&c != this) *this = c.UniChar(); return *this; }
|
||||||
|
|
||||||
#if wxUSE_UNICODE_UTF8
|
#if __cplusplus >= 201103
|
||||||
wxUniCharRef(const wxUniCharRef& that) : m_str(that.m_str), m_pos(that.m_pos) { }
|
wxUniCharRef(const wxUniCharRef&) = default;
|
||||||
#else
|
|
||||||
wxUniCharRef(const wxUniCharRef& that) : m_pos(that.m_pos) { }
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define wxUNICHAR_REF_DEFINE_OPERATOR_EQUAL(type) \
|
#define wxUNICHAR_REF_DEFINE_OPERATOR_EQUAL(type) \
|
||||||
|
Reference in New Issue
Block a user