[webkit-reviews] review granted: [Bug 217855] Fix -Wdeprecated-copy warnings in WTF and JavaScriptCore : [Attachment 411676] Patch v2

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Oct 17 14:07:05 PDT 2020


Darin Adler <darin at apple.com> has granted David Kilzer (:ddkilzer)
<ddkilzer at webkit.org>'s request for review:
Bug 217855: Fix -Wdeprecated-copy warnings in WTF and JavaScriptCore
https://bugs.webkit.org/show_bug.cgi?id=217855

Attachment 411676: Patch v2

https://bugs.webkit.org/attachment.cgi?id=411676&action=review




--- Comment #5 from Darin Adler <darin at apple.com> ---
Comment on attachment 411676
  --> https://bugs.webkit.org/attachment.cgi?id=411676
Patch v2

View in context: https://bugs.webkit.org/attachment.cgi?id=411676&action=review

r=me once it compiles

> Source/JavaScriptCore/assembler/ARM64Assembler.h:372
> +	       : data.copyTypes(other.copyTypes)

Wow, did not know this syntax existed.

Think this needs to be other.data.copyTypes.

> Source/JavaScriptCore/assembler/ARM64Assembler.h:377
> +	       data.copyTypes = other.copyTypes;

Ditto.

> Source/WTF/wtf/Identified.h:56
> +    IdentifiedBase& operator=(const IdentifiedBase& other)
> +    {
> +	   m_identifier = other.m_identifier;
> +	   return *this;
> +    }

This could also be:

    IdentifiedBase& operator=(const IdentifiedBase&) = default;

And as you did in a previous patch, could use default for the copy constructor
above, too. Not sure what your priorities are here. This way also seems fine.


More information about the webkit-reviews mailing list