Exemplo n.º 1
0
        void ParseTableSection(BinaryReader reader)
        {
            var count = Convert.ToInt32(Parser.ParseLEBSigned(reader, 32));

            if (count != 1)
            {
                throw new Exception("At most one table allowed in this version of webassembly");
            }
            var elementType = Parser.ParseLEBUnsigned(reader, 7);
            var limit       = new WebassemblyLimit(reader);

            this.table = new WebassemblyTable(elementType, limit);

            Console.WriteLine("Parsed table section. Limit is {0} {1}", limit.min, limit.max);
        }
Exemplo n.º 2
0
 public WebassemblyTable(ulong elementType, WebassemblyLimit limit)
 {
     this.limit       = limit;
     this.elementType = elementType;
 }
Exemplo n.º 3
0
 public WebassemblyMemory(WebassemblyLimit limit)
 {
     this.limit = limit;
 }