mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-09-21 20:06:40 +00:00
Explicitly default copy ctors for some classes
This fixes -Wdeprecated-copy with FreeBSD's clang17.
This commit reverts a change from 8a32b0b3d4, where a private copy
assignment operator was deleted, whereas it was needed to explicitly
declare the copy constructor, refs #5294.
This commit is contained in:
@@ -34,6 +34,8 @@ public:
|
||||
// LOGWARNING("New interned string '%s'", data.c_str());
|
||||
}
|
||||
|
||||
CStrInternInternals(const CStrInternInternals& b) = default;
|
||||
|
||||
bool operator==(const CStrInternInternals& b) const
|
||||
{
|
||||
// Compare hash first for quick rejection of inequal strings
|
||||
|
||||
@@ -91,8 +91,9 @@ const bool NOMERGE = false;
|
||||
#define COMMANDDATASTRUCT(t) \
|
||||
struct d##t { \
|
||||
private: \
|
||||
d##t& operator=(const d##t&) = delete; \
|
||||
public:
|
||||
const d##t& operator=(const d##t&); \
|
||||
public: \
|
||||
d##t(const d##t& d) = default;
|
||||
|
||||
#define COMMANDSTRUCT(t, merge) \
|
||||
struct m##t : public mWorldCommand, public d##t { \
|
||||
|
||||
Reference in New Issue
Block a user