Title: [183734] trunk/Source
Revision
183734
Author
[email protected]
Date
2015-05-03 16:58:44 -0700 (Sun, 03 May 2015)

Log Message

Make some static data const
https://bugs.webkit.org/show_bug.cgi?id=144552

Reviewed by Andreas Kling.
Source/_javascript_Core:

Turn characterSetInfo into const data.

* yarr/YarrCanonicalizeUCS2.cpp:
* yarr/YarrCanonicalizeUCS2.h:

Source/WebCore:

Turn baseTable and shiftTable into const data.

* platform/graphics/FormatConverter.cpp:

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (183733 => 183734)


--- trunk/Source/_javascript_Core/ChangeLog	2015-05-03 22:55:08 UTC (rev 183733)
+++ trunk/Source/_javascript_Core/ChangeLog	2015-05-03 23:58:44 UTC (rev 183734)
@@ -1,3 +1,15 @@
+2015-05-03  Simon Fraser  <[email protected]>
+
+        Make some static data const
+        https://bugs.webkit.org/show_bug.cgi?id=144552
+
+        Reviewed by Andreas Kling.
+        
+        Turn characterSetInfo into const data.
+
+        * yarr/YarrCanonicalizeUCS2.cpp:
+        * yarr/YarrCanonicalizeUCS2.h:
+
 2015-05-01  Filip Pizlo  <[email protected]>
 
         TypeOf should be fast

Modified: trunk/Source/_javascript_Core/yarr/YarrCanonicalizeUCS2.cpp (183733 => 183734)


--- trunk/Source/_javascript_Core/yarr/YarrCanonicalizeUCS2.cpp	2015-05-03 22:55:08 UTC (rev 183733)
+++ trunk/Source/_javascript_Core/yarr/YarrCanonicalizeUCS2.cpp	2015-05-03 23:58:44 UTC (rev 183734)
@@ -49,7 +49,7 @@
 const uint16_t ucs2CharacterSet14[] = { 0x1e60u, 0x1e61u, 0x1e9bu, 0 };
 
 static const size_t UCS2_CANONICALIZATION_SETS = 15;
-const uint16_t* characterSetInfo[UCS2_CANONICALIZATION_SETS] = {
+const uint16_t* const characterSetInfo[UCS2_CANONICALIZATION_SETS] = {
     ucs2CharacterSet0,
     ucs2CharacterSet1,
     ucs2CharacterSet2,

Modified: trunk/Source/_javascript_Core/yarr/YarrCanonicalizeUCS2.h (183733 => 183734)


--- trunk/Source/_javascript_Core/yarr/YarrCanonicalizeUCS2.h	2015-05-03 22:55:08 UTC (rev 183733)
+++ trunk/Source/_javascript_Core/yarr/YarrCanonicalizeUCS2.h	2015-05-03 23:58:44 UTC (rev 183734)
@@ -44,7 +44,7 @@
 };
 struct UCS2CanonicalizationRange { uint16_t begin, end, value, type; };
 extern const size_t UCS2_CANONICALIZATION_RANGES;
-extern const uint16_t* characterSetInfo[];
+extern const uint16_t* const characterSetInfo[];
 extern const UCS2CanonicalizationRange rangeInfo[];
 
 // This table is similar to the full rangeInfo table, however this maps from UCS2 codepoints to

Modified: trunk/Source/WebCore/ChangeLog (183733 => 183734)


--- trunk/Source/WebCore/ChangeLog	2015-05-03 22:55:08 UTC (rev 183733)
+++ trunk/Source/WebCore/ChangeLog	2015-05-03 23:58:44 UTC (rev 183734)
@@ -1,3 +1,14 @@
+2015-05-03  Simon Fraser  <[email protected]>
+
+        Make some static data const
+        https://bugs.webkit.org/show_bug.cgi?id=144552
+
+        Reviewed by Andreas Kling.
+
+        Turn baseTable and shiftTable into const data.
+
+        * platform/graphics/FormatConverter.cpp:
+
 2015-05-02  Simon Fraser  <[email protected]>
 
         Assertion failure (!needsLayout()) loading inkedmag.com

Modified: trunk/Source/WebCore/platform/graphics/FormatConverter.cpp (183733 => 183734)


--- trunk/Source/WebCore/platform/graphics/FormatConverter.cpp	2015-05-03 22:55:08 UTC (rev 183733)
+++ trunk/Source/WebCore/platform/graphics/FormatConverter.cpp	2015-05-03 23:58:44 UTC (rev 183734)
@@ -91,7 +91,7 @@
 }
 */
 
-unsigned short baseTable[512] = {
+static const unsigned short baseTable[512] = {
 0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,
 0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,
 0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,      0,
@@ -126,7 +126,7 @@
 64512,  64512,  64512,  64512,  64512,  64512,  64512,  64512,  64512,  64512,  64512,  64512,  64512,  64512,  64512,  64512
 };
 
-unsigned char shiftTable[512] = {
+static const unsigned char shiftTable[512] = {
 24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,
 24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,
 24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,     24,
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to