Index: src/wasm/module-decoder.cc |
diff --git a/src/wasm/module-decoder.cc b/src/wasm/module-decoder.cc |
index 62b000da2bfd8b3d5df0b2c612a027ffe0a64946..861c275ce93ab1066e41cdbaab8b415f1d2ff222 100644 |
--- a/src/wasm/module-decoder.cc |
+++ b/src/wasm/module-decoder.cc |
@@ -234,23 +234,16 @@ class ModuleDecoder : public Decoder { |
} |
break; |
} |
- case kDeclWLL: { |
- // Reserved for experimentation by the Web Low-level Language project |
- // which is augmenting the binary encoding with source code meta |
- // information. This section does not affect the semantics of the code |
- // and can be ignored by the runtime. https://github.com/JSStats/wll |
- int length = 0; |
- uint32_t section_size = consume_u32v(&length, "section size"); |
+ default: |
+ // All other sections are ignored and skipped. Known experimental |
+ // sections: 0x11 WLL https://github.com/JSStats/wll |
+ uint32_t section_size = consume_u32("section size"); |
if (pc_ + section_size > limit_ || pc_ + section_size < pc_) { |
- error(pc_ - length, "invalid section size"); |
+ error(pc_ - 4, "invalid section size"); |
break; |
} |
pc_ += section_size; |
break; |
- } |
- default: |
- error(pc_ - 1, nullptr, "unrecognized section 0x%02x", section); |
- break; |
} |
} |