Explorar el Código

Add Constructor to Wasm::SectionInfo to fix legacy build

Michael Ferris hace 9 años
padre
commit
38107e35d3
Se han modificado 2 ficheros con 9 adiciones y 0 borrados
  1. 8 0
      lib/WasmReader/WasmSection.cpp
  2. 1 0
      lib/WasmReader/WasmSection.h

+ 8 - 0
lib/WasmReader/WasmSection.cpp

@@ -8,6 +8,14 @@
 #ifdef ENABLE_WASM
 namespace Wasm
 {
+    SectionInfo::SectionInfo(
+        SectionFlag flag,
+        SectionCode precedent,
+        const char16* name,
+        const char* id,
+        const uint32 nameLength
+    ): flag(flag), precedent(precedent), name(name), id(id), nameLength(nameLength) {}
+
     SectionInfo SectionInfo::All[bSectLimit] = {
 #define WASM_SECTION(name, id, flag, precedent) {flag, bSect ## precedent, static_cast<const char16*>(_u(#name)), static_cast<const char*>(id), sizeof(#name)},
 #include "WasmSections.h"

+ 1 - 0
lib/WasmReader/WasmSection.h

@@ -25,6 +25,7 @@ namespace Wasm
 
     struct SectionInfo
     {
+        SectionInfo(SectionFlag, SectionCode, const char16*, const char*, const uint32);
         SectionFlag flag;
         SectionCode precedent;
         const char16* name;