Title: [242716] trunk/Source/_javascript_Core
Revision
242716
Author
[email protected]
Date
2019-03-11 10:27:47 -0700 (Mon, 11 Mar 2019)

Log Message

IntlNumberFormat can be shrunk by 16 bytes
https://bugs.webkit.org/show_bug.cgi?id=195505

Reviewed by Darin Adler.

* runtime/IntlNumberFormat.h:

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (242715 => 242716)


--- trunk/Source/_javascript_Core/ChangeLog	2019-03-11 17:21:41 UTC (rev 242715)
+++ trunk/Source/_javascript_Core/ChangeLog	2019-03-11 17:27:47 UTC (rev 242716)
@@ -1,3 +1,12 @@
+2019-03-11  Robin Morisset  <[email protected]>
+
+        IntlNumberFormat can be shrunk by 16 bytes
+        https://bugs.webkit.org/show_bug.cgi?id=195505
+
+        Reviewed by Darin Adler.
+
+        * runtime/IntlNumberFormat.h:
+
 2019-03-11  Caio Lima  <[email protected]>
 
         [ESNext][BigInt] Implement "~" unary operation

Modified: trunk/Source/_javascript_Core/runtime/IntlNumberFormat.h (242715 => 242716)


--- trunk/Source/_javascript_Core/runtime/IntlNumberFormat.h	2019-03-11 17:21:41 UTC (rev 242715)
+++ trunk/Source/_javascript_Core/runtime/IntlNumberFormat.h	2019-03-11 17:27:47 UTC (rev 242716)
@@ -64,8 +64,8 @@
     static void visitChildren(JSCell*, SlotVisitor&);
 
 private:
-    enum class Style { Decimal, Percent, Currency };
-    enum class CurrencyDisplay { Code, Symbol, Name };
+    enum class Style : uint8_t { Decimal, Percent, Currency };
+    enum class CurrencyDisplay : uint8_t { Code, Symbol, Name };
 
     struct UNumberFormatDeleter {
         void operator()(UNumberFormat*) const;
@@ -76,16 +76,16 @@
 
     String m_locale;
     String m_numberingSystem;
-    Style m_style { Style::Decimal };
     String m_currency;
-    CurrencyDisplay m_currencyDisplay;
+    std::unique_ptr<UNumberFormat, UNumberFormatDeleter> m_numberFormat;
+    WriteBarrier<JSBoundFunction> m_boundFormat;
     unsigned m_minimumIntegerDigits { 1 };
     unsigned m_minimumFractionDigits { 0 };
     unsigned m_maximumFractionDigits { 3 };
     unsigned m_minimumSignificantDigits { 0 };
     unsigned m_maximumSignificantDigits { 0 };
-    std::unique_ptr<UNumberFormat, UNumberFormatDeleter> m_numberFormat;
-    WriteBarrier<JSBoundFunction> m_boundFormat;
+    Style m_style { Style::Decimal };
+    CurrencyDisplay m_currencyDisplay;
     bool m_useGrouping { true };
     bool m_initializedNumberFormat { false };
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to