Title: [209078] trunk/Source/WebCore
Revision
209078
Author
[email protected]
Date
2016-11-29 10:53:07 -0800 (Tue, 29 Nov 2016)

Log Message

Avoid ref-count churn in CSSParser::ValueWithCalculation::setCalculation()
https://bugs.webkit.org/show_bug.cgi?id=165127

Reviewed by Simon Fraser.

Use WTFMove() to move the passed RefPtr into CSSParser::ValueWithCalculation::m_calculation
instead of copying it.

* css/parser/CSSParser.h:
(WebCore::CSSParser::ValueWithCalculation::setCalculation):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (209077 => 209078)


--- trunk/Source/WebCore/ChangeLog	2016-11-29 18:51:45 UTC (rev 209077)
+++ trunk/Source/WebCore/ChangeLog	2016-11-29 18:53:07 UTC (rev 209078)
@@ -1,5 +1,18 @@
 2016-11-29  Daniel Bates  <[email protected]>
 
+        Avoid ref-count churn in CSSParser::ValueWithCalculation::setCalculation()
+        https://bugs.webkit.org/show_bug.cgi?id=165127
+
+        Reviewed by Simon Fraser.
+
+        Use WTFMove() to move the passed RefPtr into CSSParser::ValueWithCalculation::m_calculation
+        instead of copying it.
+
+        * css/parser/CSSParser.h:
+        (WebCore::CSSParser::ValueWithCalculation::setCalculation):
+
+2016-11-29  Daniel Bates  <[email protected]>
+
         CryptoAlgorithm::generateKey() should take lvalue reference to const CryptoAlgorithmParameters
         https://bugs.webkit.org/show_bug.cgi?id=165111
 

Modified: trunk/Source/WebCore/css/parser/CSSParser.h (209077 => 209078)


--- trunk/Source/WebCore/css/parser/CSSParser.h	2016-11-29 18:51:45 UTC (rev 209077)
+++ trunk/Source/WebCore/css/parser/CSSParser.h	2016-11-29 18:53:07 UTC (rev 209078)
@@ -117,7 +117,7 @@
         void setCalculation(RefPtr<CSSCalcValue>&& calculation)
         {
             ASSERT(isCalculation(m_value));
-            m_calculation = calculation;
+            m_calculation = WTFMove(calculation);
         }
 
     private:
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to