[webkit-reviews] review requested: [Bug 212379] [WTF] Implement new BoxPtr alias : [Attachment 403705] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jul 7 10:04:52 PDT 2020


Xabier Rodríguez Calvar <calvaris at igalia.com> has asked  for review:
Bug 212379: [WTF] Implement new BoxPtr alias
https://bugs.webkit.org/show_bug.cgi?id=212379

Attachment 403705: Patch

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




--- Comment #20 from Xabier Rodríguez Calvar <calvaris at igalia.com> ---
Created attachment 403705

  --> https://bugs.webkit.org/attachment.cgi?id=403705&action=review

Patch

Addressed all comments.

(In reply to Darin Adler from comment #18)
> > Source/WTF/wtf/BoxPtr.h:58
> > +bool operator==(const BoxPtr<T>& lhs, const BoxPtr<T>& rhs)
> 
> This is quite risky. Doing this for == and not !=, and also the effect this
> could have a generic code that really does need to do a pointer equality. I
> understand this is the heart of what you mean by using a pointer to box
> something, but I am quite concerned that this technique may not work well.

In my use case it helps, otherwise I would have to do the comparison by myself.


More information about the webkit-reviews mailing list