Commit fb7a2445 by Gert Wollny Committed by Commit Bot

libANGLE: Declare copy operator if copy constructor is defined

If the copy constructor is defined then the copy assignment must also be defined, but we can use the default here. v2: Don't inline because the chromium-style errors out on this Bug: angleproject:4486 Change-Id: Iec0f63342244249da32b455b49a0b89b6558cab9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2690953Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org> Reviewed-by: 's avatarGeoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
parent 0e11e49d
......@@ -11,10 +11,12 @@
namespace egl
{
AttributeMap::AttributeMap() {}
AttributeMap::AttributeMap() = default;
AttributeMap::AttributeMap(const AttributeMap &other) = default;
AttributeMap &AttributeMap::operator=(const AttributeMap &other) = default;
AttributeMap::~AttributeMap() = default;
void AttributeMap::insert(EGLAttrib key, EGLAttrib value)
......
......@@ -22,6 +22,7 @@ class AttributeMap final
public:
AttributeMap();
AttributeMap(const AttributeMap &other);
AttributeMap &operator=(const AttributeMap &other);
~AttributeMap();
void insert(EGLAttrib key, EGLAttrib value);
......
......@@ -34,6 +34,8 @@ TextureCaps::TextureCaps() = default;
TextureCaps::TextureCaps(const TextureCaps &other) = default;
TextureCaps &TextureCaps::operator=(const TextureCaps &other) = default;
TextureCaps::~TextureCaps() = default;
GLuint TextureCaps::getMaxSamples() const
......@@ -1123,6 +1125,7 @@ void TypePrecision::get(GLint *returnRange, GLint *returnPrecision) const
Caps::Caps() = default;
Caps::Caps(const Caps &other) = default;
Caps::~Caps() = default;
Caps &Caps::operator=(const Caps &other) = default;
Caps GenerateMinimumCaps(const Version &clientVersion, const Extensions &extensions)
{
......
......@@ -27,6 +27,8 @@ struct TextureCaps
{
TextureCaps();
TextureCaps(const TextureCaps &other);
TextureCaps &operator=(const TextureCaps &other);
~TextureCaps();
// Supports for basic texturing: glTexImage, glTexSubImage, etc
......@@ -797,6 +799,8 @@ struct Caps
{
Caps();
Caps(const Caps &other);
Caps &operator=(const Caps &other);
~Caps();
// If the values could be got by using GetIntegeri_v, they should
......
......@@ -30,7 +30,9 @@ SupportRequirement::SupportRequirement()
SupportRequirement::SupportRequirement(const SupportRequirement &other) = default;
SupportRequirement::~SupportRequirement() {}
SupportRequirement &SupportRequirement::operator=(const SupportRequirement &other) = default;
SupportRequirement::~SupportRequirement() = default;
InternalFormat::InternalFormat() : texture(), filter(), textureAttachment(), renderbuffer() {}
......
......@@ -33,6 +33,8 @@ struct SupportRequirement
{
SupportRequirement();
SupportRequirement(const SupportRequirement &other);
SupportRequirement &operator=(const SupportRequirement &other);
~SupportRequirement();
// Version that this format became supported without extensions
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment