Adding static method zeroPoint to class IntPoint.
Created attachment 52757 [details] Patch
Comment on attachment 52757 [details] Patch If it's a class member, then it's IntPoint::zeroPoint(), which is worse than IntPoint(). I think we either need it to be: inline IntPoint zeroIntPoint() { return IntPoint(); } Or: static IntPoint zero() { return IntPoint(); } So we don't repeat the word point twice. I also think we should do this for FloatPoint too.
(In reply to comment #2) > inline IntPoint zeroIntPoint() { return IntPoint(); } Outside the class, so it would be "zeroIntPoint()" at the call site. > static IntPoint zero() { return IntPoint(); } Inside the class, so it would be "IntPoint::zero()" at the call site.
Created attachment 52776 [details] Patch
Comment on attachment 52776 [details] Patch Thanks for implementing my suggestion. I think using this at various call sites instead of IntPoint() or IntPoint(0, 0) will make things a little more readable.
Comment on attachment 52776 [details] Patch Clearing flags on attachment: 52776 Committed r57236: <http://trac.webkit.org/changeset/57236>
All reviewed patches have been landed. Closing bug.