Title: [143361] trunk/Source/WebCore
Revision
143361
Author
commit-qu...@webkit.org
Date
2013-02-19 11:10:45 -0800 (Tue, 19 Feb 2013)

Log Message

Remove unnecessary (and problematic) copy-constructor from LayoutUnit
https://bugs.webkit.org/show_bug.cgi?id=110121

This copy constructor does what a default copy constructor would do, so
it's not necessary. Furthermore, this copy constructor is the only
reason why LayoutUnit becomes non-POD, and that triggers a gdb bug,
making it impossible to do things like "print location()" when inside
some RenderBlock, for instance.

Gdb bug http://sourceware.org/bugzilla/show_bug.cgi?id=15154 reported.

Patch by Morten Stenshorne <msten...@opera.com> on 2013-02-19
Reviewed by Benjamin Poulain.

No tests. Apart from dealing with buggy debuggers, this is just code cleanup.

* platform/LayoutUnit.h:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (143360 => 143361)


--- trunk/Source/WebCore/ChangeLog	2013-02-19 19:10:27 UTC (rev 143360)
+++ trunk/Source/WebCore/ChangeLog	2013-02-19 19:10:45 UTC (rev 143361)
@@ -1,3 +1,22 @@
+2013-02-19  Morten Stenshorne  <msten...@opera.com>
+
+        Remove unnecessary (and problematic) copy-constructor from LayoutUnit
+        https://bugs.webkit.org/show_bug.cgi?id=110121
+
+        This copy constructor does what a default copy constructor would do, so
+        it's not necessary. Furthermore, this copy constructor is the only
+        reason why LayoutUnit becomes non-POD, and that triggers a gdb bug,
+        making it impossible to do things like "print location()" when inside
+        some RenderBlock, for instance.
+
+        Gdb bug http://sourceware.org/bugzilla/show_bug.cgi?id=15154 reported.
+
+        Reviewed by Benjamin Poulain.
+
+        No tests. Apart from dealing with buggy debuggers, this is just code cleanup.
+
+        * platform/LayoutUnit.h:
+
 2013-02-19  Emil A Eklund  <e...@chromium.org>
 
         LayoutUnit::epsilon shouldn't be necessary to place floats

Modified: trunk/Source/WebCore/platform/LayoutUnit.h (143360 => 143361)


--- trunk/Source/WebCore/platform/LayoutUnit.h	2013-02-19 19:10:27 UTC (rev 143360)
+++ trunk/Source/WebCore/platform/LayoutUnit.h	2013-02-19 19:10:45 UTC (rev 143361)
@@ -116,7 +116,6 @@
     LayoutUnit(float value) { REPORT_OVERFLOW(isInBounds(value)); m_value = value; }
     LayoutUnit(double value) { REPORT_OVERFLOW(isInBounds(value)); m_value = value; }
 #endif
-    LayoutUnit(const LayoutUnit& value) { m_value = value.rawValue(); }
 
     static LayoutUnit fromFloatCeil(float value)
     {
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to