Remove wxNODISCARD from wxBasicString::Get() declaration

Using both wxDEPRECATED_MSG and wxNODISCARD for some reason breaks
compilation with clang (when using C++17 or newer standard).

Since wxBasicString::Get() is deprecated, one warning should be enough
so just remove wxNODISCARD from the method declaration.

Closes #23952.
This commit is contained in:
PB 2023-10-09 09:00:33 +02:00
parent 4235a018be
commit b87a7ab9e7

View file

@ -104,7 +104,7 @@ public:
// retrieve a copy of our string - caller must SysFreeString() it later!
wxDEPRECATED_MSG("use Copy() instead")
wxNODISCARD BSTR Get() const { return Copy(); }
BSTR Get() const { return Copy(); }
private:
// actual string
BSTR m_bstrBuf;