2
0

WasmSection.h 978 B

123456789101112131415161718192021222324252627282930313233343536
  1. //-------------------------------------------------------------------------------------------------------
  2. // Copyright (C) Microsoft. All rights reserved.
  3. // Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
  4. //-------------------------------------------------------------------------------------------------------
  5. #pragma once
  6. #ifdef ENABLE_WASM
  7. namespace Wasm
  8. {
  9. enum SectionFlag
  10. {
  11. fSectNone,
  12. fSectIgnore,
  13. };
  14. #define WASM_SECTION(intName, id, flag, precendent) bSect ## intName,
  15. enum SectionCode : uint8
  16. {
  17. #include "WasmSections.h"
  18. bSectLimit,
  19. bsectLastKnownSection = bSectData
  20. };
  21. struct SectionInfo
  22. {
  23. SectionInfo(SectionFlag, SectionCode, const char16*, const uint32);
  24. SectionFlag flag;
  25. SectionCode precedent;
  26. const char16* name;
  27. const uint32 nameLength;
  28. static SectionInfo All[bSectLimit];
  29. };
  30. }
  31. #endif