Bug 1331939 - Rename GlobalFlags to GlobalTypeImmediate to fix MinGW build. r=luke, a=gchang
authorTom Ritter <tom@mozilla.com>
Tue, 24 Jan 2017 15:00:42 -0600
changeset 375898 e2782cbfdefff36f45c159d8a8b3001db173f46b
parent 375897 2ec21157f2b5cb7ae7644d733ee0bb0451ae3d31
child 375899 c02020dd7e6e190b046e0bdc992a75b647c4cffa
push id6996
push userjlorenzo@mozilla.com
push dateMon, 06 Mar 2017 20:48:21 +0000
treeherdermozilla-beta@d89512dab048 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersluke, gchang
bugs1331939
milestone53.0a2
Bug 1331939 - Rename GlobalFlags to GlobalTypeImmediate to fix MinGW build. r=luke, a=gchang MozReview-Commit-ID: 1jXd3LUZ0dT
js/src/wasm/WasmBinaryConstants.h
js/src/wasm/WasmTextToBinary.cpp
js/src/wasm/WasmValidate.cpp
--- a/js/src/wasm/WasmBinaryConstants.h
+++ b/js/src/wasm/WasmBinaryConstants.h
@@ -98,17 +98,17 @@ typedef Vector<ValType, 8, SystemAllocPo
 enum class DefinitionKind
 {
     Function                             = 0x00,
     Table                                = 0x01,
     Memory                               = 0x02,
     Global                               = 0x03
 };
 
-enum class GlobalFlags
+enum class GlobalTypeImmediate
 {
     IsMutable                            = 0x1,
     AllowedMask                          = 0x1
 };
 
 enum class MemoryTableFlags
 {
     Default                              = 0x0
--- a/js/src/wasm/WasmTextToBinary.cpp
+++ b/js/src/wasm/WasmTextToBinary.cpp
@@ -4432,17 +4432,17 @@ EncodeTableLimits(Encoder& e, const Limi
 
     return EncodeLimits(e, limits);
 }
 
 static bool
 EncodeGlobalType(Encoder& e, const AstGlobal* global)
 {
     return e.writeValType(global->type()) &&
-           e.writeVarU32(global->isMutable() ? uint32_t(GlobalFlags::IsMutable) : 0);
+           e.writeVarU32(global->isMutable() ? uint32_t(GlobalTypeImmediate::IsMutable) : 0);
 }
 
 static bool
 EncodeImport(Encoder& e, AstImport& imp)
 {
     if (!EncodeBytes(e, imp.module()))
         return false;
 
--- a/js/src/wasm/WasmValidate.cpp
+++ b/js/src/wasm/WasmValidate.cpp
@@ -909,20 +909,20 @@ DecodeGlobalType(Decoder& d, ValType* ty
 {
     if (!DecodeValType(d, ModuleKind::Wasm, type))
         return false;
 
     uint32_t flags;
     if (!d.readVarU32(&flags))
         return d.fail("expected global flags");
 
-    if (flags & ~uint32_t(GlobalFlags::AllowedMask))
+    if (flags & ~uint32_t(GlobalTypeImmediate::AllowedMask))
         return d.fail("unexpected bits set in global flags");
 
-    *isMutable = flags & uint32_t(GlobalFlags::IsMutable);
+    *isMutable = flags & uint32_t(GlobalTypeImmediate::IsMutable);
     return true;
 }
 
 static bool
 DecodeMemoryLimits(Decoder& d, ModuleEnvironment* env)
 {
     if (env->usesMemory())
         return d.fail("already have default memory");