Bug 1476485 - Remove pragma pack from nsUnicodeScriptCodes.h. r?jfkthame draft
authorXidorn Quan <me@upsuper.org>
Wed, 18 Jul 2018 14:05:05 +1000
changeset 819552 bb8b43a9ede7ac62d765e75e5f18ecf82e8bfc48
parent 819551 ca04dcecfc6c5334e1850accf654db5970604a76
push id116578
push userxquan@mozilla.com
push dateWed, 18 Jul 2018 04:06:19 +0000
reviewersjfkthame
bugs1476485
milestone63.0a1
Bug 1476485 - Remove pragma pack from nsUnicodeScriptCodes.h. r?jfkthame MozReview-Commit-ID: LW64U7ccjVa
intl/unicharutil/tools/genUnicodePropertyData.pl
intl/unicharutil/util/nsUnicodeScriptCodes.h
--- a/intl/unicharutil/tools/genUnicodePropertyData.pl
+++ b/intl/unicharutil/tools/genUnicodePropertyData.pl
@@ -340,18 +340,16 @@ print HEADER <<__END;
 
 #ifndef NS_UNICODE_SCRIPT_CODES
 #define NS_UNICODE_SCRIPT_CODES
 
 __END
 
 our $totalData = 0;
 
-print HEADER "#pragma pack(1)\n\n";
-
 sub sprintCharProps2_short
 {
   my $usv = shift;
   return sprintf("{%d,%d},",
                  $verticalOrientation[$usv], $idtype[$usv]);
 }
 my $type = q|
 struct nsCharProps2 {
@@ -359,18 +357,16 @@ struct nsCharProps2 {
   // affecting the storage requirements for this struct. Or we could pack two
   // records per byte, at the cost of a slightly more complex accessor.
   unsigned char mVertOrient:2;
   unsigned char mIdType:2;
 };
 |;
 &genTables("CharProp2", $type, "nsCharProps2", 9, 7, \&sprintCharProps2_short, 16, 1, 1);
 
-print HEADER "#pragma pack()\n\n";
-
 sub sprintHanVariants
 {
   my $baseUsv = shift;
   my $varShift = 0;
   my $val = 0;
   while ($varShift < 8) {
     $val |= $hanVariant[$baseUsv++] << $varShift;
     $varShift += 2;
--- a/intl/unicharutil/util/nsUnicodeScriptCodes.h
+++ b/intl/unicharutil/util/nsUnicodeScriptCodes.h
@@ -42,29 +42,24 @@ for the Unicode Character Database, for 
 
  *
  * * * * * This file contains MACHINE-GENERATED DATA, do not edit! * * * * *
  */
 
 #ifndef NS_UNICODE_SCRIPT_CODES
 #define NS_UNICODE_SCRIPT_CODES
 
-#pragma pack(1)
-
-
 struct nsCharProps2 {
   // Currently only 4 bits are defined here, so 4 more could be added without
   // affecting the storage requirements for this struct. Or we could pack two
   // records per byte, at the cost of a slightly more complex accessor.
   unsigned char mVertOrient:2;
   unsigned char mIdType:2;
 };
 
-#pragma pack()
-
 namespace mozilla {
 namespace unicode {
 enum class Script : int16_t {
   COMMON = 0,
   INHERITED = 1,
   ARABIC = 2,
   ARMENIAN = 3,
   BENGALI = 4,