Fix IVariant -Wdeprecated-copy-with-dtor
Since C++11 the generation of implicit copy constructor is deprecated if the type has a user-defined constructor or destructor (even if defaulted). Same thing for the implicit copy assignment operator. Fix this by adding a defaulted copy-constructor for IVariant that remove the implicit default constructor, so add it too.
This commit is contained in:
parent
2e1b5fb39e
commit
6a85c695cc
@ -417,6 +417,11 @@ struct IVariant
|
||||
virtual ~IVariant() = default;
|
||||
virtual IVariant *clone(ObjectPoolBase *pool) = 0;
|
||||
ID self = 0;
|
||||
|
||||
protected:
|
||||
IVariant() = default;
|
||||
IVariant(const IVariant&) = default;
|
||||
IVariant &operator=(const IVariant&) = default;
|
||||
};
|
||||
|
||||
#define SPIRV_CROSS_DECLARE_CLONE(T) \
|
||||
|
Loading…
Reference in New Issue
Block a user