[webkit-reviews] review granted: [Bug 186314] [Cocoa] More preparation for ARC, focusing on WebKit and smart pointers : [Attachment 341984] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jun 5 13:09:51 PDT 2018


Anders Carlsson <andersca at apple.com> has granted Darin Adler
<darin at apple.com>'s request for review:
Bug 186314: [Cocoa] More preparation for ARC, focusing on WebKit and smart
pointers
https://bugs.webkit.org/show_bug.cgi?id=186314

Attachment 341984: Patch

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




--- Comment #2 from Anders Carlsson <andersca at apple.com> ---
Comment on attachment 341984
  --> https://bugs.webkit.org/attachment.cgi?id=341984
Patch

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

> Source/WTF/wtf/BlockPtr.h:100
> +#if defined(__OBJC__) && __has_feature(objc_arc)

__has_feature(objc_arc) always implies __OBJC__ being defined, so you don't
need to check for __OBJC__ here (or anywhere else).

> Source/WTF/wtf/OSObjectPtr.h:120
> +	   OSObjectPtr ptr = other;

I think you can use std::move(other) here - under ARC Objective-C pointers have
implicit move constructors.


More information about the webkit-reviews mailing list