[Webkit-unassigned] [Bug 162302] [GTK] webkit-gtk-2.14.0 build failure of ScrollbarThemeGtk with libc++

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Sep 20 23:13:30 PDT 2016


https://bugs.webkit.org/show_bug.cgi?id=162302

Carlos Garcia Campos <cgarcia at igalia.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #289387|review+                     |review-
              Flags|                            |

--- Comment #6 from Carlos Garcia Campos <cgarcia at igalia.com> ---
Comment on attachment 289387
  --> https://bugs.webkit.org/attachment.cgi?id=289387
0002-GTK-Fix-build-failure-of-ScrollbarThemeGtk-with-libc

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

> Source/WebCore/platform/gtk/ScrollbarThemeGtk.cpp:547
> -                contentsRect.move(std::abs(rect.width() - preferredSize.width()), 0);
> +                contentsRect.move(std::abs((double)(rect.width() - preferredSize.width())), 0);

I think it would be cleaner to cast the result of abs, because both rect and preferredSize are ints, instead of using the abs overload for floats with integers, we could use the int one and cast the result. Another way to disambiguate this could be using std::fabs, adn then we don't need any ugly cast.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160921/b598fb6b/attachment.html>


More information about the webkit-unassigned mailing list