Repository: bytecodealliance/wasm-tools
Pull request #1500 (2024-04-16 18:05:41)

Release wasm-tools 1.204.0
This is an automated pull request from CI to release
wasm-tools 1.204.0 when merged. The commit
message for this PR has a marker that is detected by CI to create
tags and publish crate artifacts.

When first opened this PR will not have CI run because it is generated
by a bot. A maintainer should close this PR and then reopen it to
trigger CI to execute which will then enable merging this PR.


Patch:
diff --git a/Cargo.lock b/Cargo.lock
index 58a5ba65..5b21c748 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -1728,7 +1728,7 @@ checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96"
 
 [[package]]
 name = "wasm-compose"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "anyhow",
  "glob",
@@ -1742,9 +1742,9 @@ dependencies = [
  "serde_derive",
  "serde_yaml",
  "smallvec",
- "wasm-encoder 0.203.0",
- "wasmparser 0.203.0",
- "wasmprinter 0.203.0",
+ "wasm-encoder 0.204.0",
+ "wasmparser 0.204.0",
+ "wasmprinter 0.204.0",
  "wat",
  "wit-component",
 ]
@@ -1760,17 +1760,17 @@ dependencies = [
 
 [[package]]
 name = "wasm-encoder"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "anyhow",
  "leb128",
  "tempfile",
- "wasmparser 0.203.0",
+ "wasmparser 0.204.0",
 ]
 
 [[package]]
 name = "wasm-metadata"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "anyhow",
  "clap 4.5.2",
@@ -1779,14 +1779,14 @@ dependencies = [
  "serde_derive",
  "serde_json",
  "spdx",
- "wasm-encoder 0.203.0",
- "wasmparser 0.203.0",
+ "wasm-encoder 0.204.0",
+ "wasmparser 0.204.0",
  "wat",
 ]
 
 [[package]]
 name = "wasm-mutate"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "anyhow",
  "clap 4.5.2",
@@ -1795,9 +1795,9 @@ dependencies = [
  "log",
  "rand",
  "thiserror",
- "wasm-encoder 0.203.0",
- "wasmparser 0.203.0",
- "wasmprinter 0.203.0",
+ "wasm-encoder 0.204.0",
+ "wasmparser 0.204.0",
+ "wasmprinter 0.204.0",
  "wat",
 ]
 
@@ -1814,14 +1814,14 @@ dependencies = [
  "num_cpus",
  "rand",
  "wasm-mutate",
- "wasmparser 0.203.0",
- "wasmprinter 0.203.0",
+ "wasmparser 0.204.0",
+ "wasmprinter 0.204.0",
  "wasmtime",
 ]
 
 [[package]]
 name = "wasm-shrink"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "anyhow",
  "blake3",
@@ -1830,14 +1830,14 @@ dependencies = [
  "log",
  "rand",
  "wasm-mutate",
- "wasmparser 0.203.0",
- "wasmprinter 0.203.0",
+ "wasmparser 0.204.0",
+ "wasmprinter 0.204.0",
  "wat",
 ]
 
 [[package]]
 name = "wasm-smith"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "anyhow",
  "arbitrary",
@@ -1850,15 +1850,15 @@ dependencies = [
  "rand",
  "serde",
  "serde_derive",
- "wasm-encoder 0.203.0",
- "wasmparser 0.203.0",
- "wasmprinter 0.203.0",
+ "wasm-encoder 0.204.0",
+ "wasmparser 0.204.0",
+ "wasmprinter 0.204.0",
  "wat",
 ]
 
 [[package]]
 name = "wasm-tools"
-version = "1.203.0"
+version = "1.204.0"
 dependencies = [
  "addr2line 0.21.0",
  "anyhow",
@@ -1882,17 +1882,17 @@ dependencies = [
  "tempfile",
  "termcolor",
  "wasm-compose",
- "wasm-encoder 0.203.0",
+ "wasm-encoder 0.204.0",
  "wasm-metadata",
  "wasm-mutate",
  "wasm-shrink",
  "wasm-smith",
- "wasmparser 0.203.0",
- "wasmprinter 0.203.0",
+ "wasmparser 0.204.0",
+ "wasmprinter 0.204.0",
  "wast",
  "wat",
  "wit-component",
- "wit-parser 0.203.0",
+ "wit-parser 0.204.0",
  "wit-smith",
 ]
 
@@ -1904,8 +1904,8 @@ dependencies = [
  "wasm-mutate",
  "wasm-shrink",
  "wasm-smith",
- "wasmparser 0.203.0",
- "wasmprinter 0.203.0",
+ "wasmparser 0.204.0",
+ "wasmprinter 0.204.0",
  "wast",
  "wat",
 ]
@@ -1920,16 +1920,16 @@ dependencies = [
  "libfuzzer-sys",
  "log",
  "tempfile",
- "wasm-encoder 0.203.0",
+ "wasm-encoder 0.204.0",
  "wasm-mutate",
  "wasm-smith",
- "wasmparser 0.203.0",
- "wasmprinter 0.203.0",
+ "wasmparser 0.204.0",
+ "wasmprinter 0.204.0",
  "wasmtime",
  "wast",
  "wat",
  "wit-component",
- "wit-parser 0.203.0",
+ "wit-parser 0.204.0",
  "wit-smith",
 ]
 
@@ -1956,7 +1956,7 @@ dependencies = [
 
 [[package]]
 name = "wasmparser"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "anyhow",
  "bitflags 2.4.2",
@@ -1967,7 +1967,7 @@ dependencies = [
  "once_cell",
  "rayon",
  "semver",
- "wasm-encoder 0.203.0",
+ "wasm-encoder 0.204.0",
  "wast",
  "wat",
 ]
@@ -1984,13 +1984,13 @@ dependencies = [
 
 [[package]]
 name = "wasmprinter"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "anyhow",
  "diff",
  "rayon",
  "tempfile",
- "wasmparser 0.203.0",
+ "wasmparser 0.204.0",
  "wast",
  "wat",
 ]
@@ -2248,7 +2248,7 @@ dependencies = [
 
 [[package]]
 name = "wast"
-version = "203.0.0"
+version = "204.0.0"
 dependencies = [
  "anyhow",
  "bumpalo",
@@ -2256,14 +2256,14 @@ dependencies = [
  "libtest-mimic",
  "memchr",
  "unicode-width",
- "wasm-encoder 0.203.0",
- "wasmparser 0.203.0",
+ "wasm-encoder 0.204.0",
+ "wasmparser 0.204.0",
  "wat",
 ]
 
 [[package]]
 name = "wat"
-version = "1.203.0"
+version = "1.204.0"
 dependencies = [
  "wast",
 ]
@@ -2459,7 +2459,7 @@ checksum = "32b752e52a2da0ddfbdbcc6fceadfeede4c939ed16d13e648833a61dfb611ed8"
 
 [[package]]
 name = "wit-component"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "anyhow",
  "bitflags 2.4.2",
@@ -2471,14 +2471,14 @@ dependencies = [
  "serde",
  "serde_derive",
  "serde_json",
- "wasm-encoder 0.203.0",
+ "wasm-encoder 0.204.0",
  "wasm-metadata",
- "wasmparser 0.203.0",
- "wasmprinter 0.203.0",
+ "wasmparser 0.204.0",
+ "wasmprinter 0.204.0",
  "wasmtime",
  "wast",
  "wat",
- "wit-parser 0.203.0",
+ "wit-parser 0.204.0",
 ]
 
 [[package]]
@@ -2499,7 +2499,7 @@ dependencies = [
 
 [[package]]
 name = "wit-parser"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "anyhow",
  "env_logger",
@@ -2513,9 +2513,9 @@ dependencies = [
  "serde_derive",
  "serde_json",
  "unicode-xid",
- "wasmparser 0.203.0",
+ "wasmparser 0.204.0",
  "wat",
- "wit-parser 0.203.0",
+ "wit-parser 0.204.0",
 ]
 
 [[package]]
@@ -2526,13 +2526,13 @@ dependencies = [
  "env_logger",
  "libfuzzer-sys",
  "log",
- "wasmprinter 0.203.0",
- "wit-parser 0.203.0",
+ "wasmprinter 0.204.0",
+ "wit-parser 0.204.0",
 ]
 
 [[package]]
 name = "wit-smith"
-version = "0.203.0"
+version = "0.204.0"
 dependencies = [
  "arbitrary",
  "clap 4.5.2",
@@ -2540,7 +2540,7 @@ dependencies = [
  "log",
  "semver",
  "wit-component",
- "wit-parser 0.203.0",
+ "wit-parser 0.204.0",
 ]
 
 [[package]]
diff --git a/Cargo.toml b/Cargo.toml
index c2da1911..fff43def 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -1,6 +1,6 @@
 [package]
 name = "wasm-tools"
-version = "1.203.0"
+version = "1.204.0"
 authors = ["The Wasmtime Project Developers"]
 edition.workspace = true
 description = "CLI tools for interoperating with WebAssembly files"
@@ -33,7 +33,7 @@ all = "allow"
 
 [workspace.package]
 edition = '2021'
-version = "0.203.0"
+version = "0.204.0"
 
 [workspace.dependencies]
 anyhow = "1.0.58"
@@ -60,19 +60,19 @@ smallvec = "1.11.1"
 libtest-mimic = "0.7.0"
 bitflags = "2.5.0"
 
-wasm-compose = { version = "0.203.0", path = "crates/wasm-compose" }
-wasm-encoder = { version = "0.203.0", path = "crates/wasm-encoder" }
-wasm-metadata = { version = "0.203.0", path = "crates/wasm-metadata" }
-wasm-mutate = { version = "0.203.0", path = "crates/wasm-mutate" }
-wasm-shrink = { version = "0.203.0", path = "crates/wasm-shrink" }
-wasm-smith = { version = "0.203.0", path = "crates/wasm-smith" }
-wasmparser = { version = "0.203.0", path = "crates/wasmparser" }
-wasmprinter = { version = "0.203.0", path = "crates/wasmprinter" }
-wast = { version = "203.0.0", path = "crates/wast" }
-wat = { version = "1.203.0", path = "crates/wat" }
-wit-component = { version = "0.203.0", path = "crates/wit-component" }
-wit-parser = { version = "0.203.0", path = "crates/wit-parser" }
-wit-smith = { version = "0.203.0", path = "crates/wit-smith" }
+wasm-compose = { version = "0.204.0", path = "crates/wasm-compose" }
+wasm-encoder = { version = "0.204.0", path = "crates/wasm-encoder" }
+wasm-metadata = { version = "0.204.0", path = "crates/wasm-metadata" }
+wasm-mutate = { version = "0.204.0", path = "crates/wasm-mutate" }
+wasm-shrink = { version = "0.204.0", path = "crates/wasm-shrink" }
+wasm-smith = { version = "0.204.0", path = "crates/wasm-smith" }
+wasmparser = { version = "0.204.0", path = "crates/wasmparser" }
+wasmprinter = { version = "0.204.0", path = "crates/wasmprinter" }
+wast = { version = "204.0.0", path = "crates/wast" }
+wat = { version = "1.204.0", path = "crates/wat" }
+wit-component = { version = "0.204.0", path = "crates/wit-component" }
+wit-parser = { version = "0.204.0", path = "crates/wit-parser" }
+wit-smith = { version = "0.204.0", path = "crates/wit-smith" }
 
 [dependencies]
 anyhow = { workspace = true }
diff --git a/crates/wasmparser/src/validator.rs b/crates/wasmparser/src/validator.rs
index 8df6535b..00810fc2 100644
--- a/crates/wasmparser/src/validator.rs
+++ b/crates/wasmparser/src/validator.rs
@@ -198,33 +198,110 @@ impl Default for State {
     }
 }
 
-bitflags! {
+macro_rules! define_wasm_features {
+    (
+        $(#[$outer:meta])*
+        pub struct WasmFeatures: $repr:ty {
+            $(
+                $(#[$inner:ident $($args:tt)*])*
+                pub $field:ident: $const:ident($flag:expr) = $default:expr;
+            )*
+        }
+    ) => {
+        bitflags! {
+            $(#[$outer])*
+            pub struct WasmFeatures: $repr {
+                $(
+                    $(#[$inner $($args)*])*
+                    #[doc = "\nDefaults to `"]
+                    #[doc = stringify!($default)]
+                    #[doc = "`.\n"]
+                    const $const = $flag;
+                )*
+            }
+        }
+
+        impl Default for WasmFeatures {
+            #[inline]
+            fn default() -> Self {
+                let mut features = WasmFeatures::empty();
+                $(
+                    features.set(WasmFeatures::$const, $default);
+                )*
+                features
+            }
+        }
+
+        impl WasmFeatures {
+            /// Construct a bit-packed `WasmFeatures` from the inflated struct version.
+            #[inline]
+            pub fn from_inflated(inflated: WasmFeaturesInflated) -> Self {
+                let mut features = WasmFeatures::empty();
+                $(
+                    features.set(WasmFeatures::$const, inflated.$field);
+                )*
+                features
+            }
+
+            /// Inflate these bit-packed features into a struct with a field per
+            /// feature.
+            ///
+            /// Although the inflated struct takes up much more memory than the
+            /// bit-packed version, its fields can be exhaustively matched
+            /// upon. This makes it useful for temporarily checking against,
+            /// while keeping the bit-packed version as the method of storing
+            /// the features for longer periods of time.
+            #[inline]
+            pub fn inflate(&self) -> WasmFeaturesInflated {
+                WasmFeaturesInflated {
+                    $(
+                        $field: self.contains(WasmFeatures::$const),
+                    )*
+                }
+            }
+        }
+
+        /// Inflated version of [`WasmFeatures`][crate::WasmFeatures] that
+        /// allows for exhaustive matching on fields.
+        pub struct WasmFeaturesInflated {
+            $(
+                $(#[$inner $($args)*])*
+                #[doc = "\nDefaults to `"]
+                #[doc = stringify!($default)]
+                #[doc = "`.\n"]
+                pub $field: bool,
+            )*
+        }
+    };
+}
+
+define_wasm_features! {
     /// Flags for features that are enabled for validation.
     #[derive(Hash, Debug, Copy, Clone)]
     pub struct WasmFeatures: u32 {
-        /// The WebAssembly `mutable-global` proposal (enabled by default)
-        const MUTABLE_GLOBAL = 1;
-        /// The WebAssembly `saturating-float-to-int` proposal (enabled by default)
-        const SATURATING_FLOAT_TO_INT = 1 << 1;
-        /// The WebAssembly `sign-extension-ops` proposal (enabled by default)
-        const SIGN_EXTENSION = 1 << 2;
-        /// The WebAssembly reference types proposal (enabled by default)
-        const REFERENCE_TYPES = 1 << 3;
-        /// The WebAssembly multi-value proposal (enabled by default)
-        const MULTI_VALUE = 1 << 4;
-        /// The WebAssembly bulk memory operations proposal (enabled by default)
-        const BULK_MEMORY = 1 << 5;
-        /// The WebAssembly SIMD proposal (enabled by default)
-        const SIMD = 1 << 6;
-        /// The WebAssembly Relaxed SIMD proposal (enabled by default)
-        const RELAXED_SIMD = 1 << 7;
-        /// The WebAssembly threads proposal (enabled by default)
-        const THREADS = 1 << 8;
+        /// The WebAssembly `mutable-global` proposal.
+        pub mutable_global: MUTABLE_GLOBAL(1) = true;
+        /// The WebAssembly `saturating-float-to-int` proposal.
+        pub saturating_float_to_int: SATURATING_FLOAT_TO_INT(1 << 1) = true;
+        /// The WebAssembly `sign-extension-ops` proposal.
+        pub sign_extension: SIGN_EXTENSION(1 << 2) = true;
+        /// The WebAssembly reference types proposal.
+        pub reference_types: REFERENCE_TYPES(1 << 3) = true;
+        /// The WebAssembly multi-value proposal.
+        pub multi_value: MULTI_VALUE(1 << 4) = true;
+        /// The WebAssembly bulk memory operations proposal.
+        pub bulk_memory: BULK_MEMORY(1 << 5) = true;
+        /// The WebAssembly SIMD proposal.
+        pub simd: SIMD(1 << 6) = true;
+        /// The WebAssembly Relaxed SIMD proposal.
+        pub relaxed_simd: RELAXED_SIMD(1 << 7) = true;
+        /// The WebAssembly threads proposal.
+        pub threads: THREADS(1 << 8) = true;
         /// The WebAssembly shared-everything-threads proposal; includes new
         /// component model built-ins.
-        const SHARED_EVERYTHING_THREADS = 1 << 9;
-        /// The WebAssembly tail-call proposal (enabled by default)
-        const TAIL_CALL = 1 << 10;
+        pub shared_everything_threads: SHARED_EVERYTHING_THREADS(1 << 9) = false;
+        /// The WebAssembly tail-call proposal.
+        pub tail_call: TAIL_CALL(1 << 10) = true;
         /// Whether or not floating-point instructions are enabled.
         ///
         /// This is enabled by default can be used to disallow floating-point
@@ -235,30 +312,44 @@ bitflags! {
         /// about execution. Floats in WebAssembly can have different NaN patterns
         /// across hosts which can lead to host-dependent execution which some
         /// runtimes may not desire.
-        const FLOATS = 1 << 11;
-        /// The WebAssembly multi memory proposal (enabled by default)
-        const MULTI_MEMORY = 1 << 12;
-        /// The WebAssembly exception handling proposal
-        const EXCEPTIONS = 1 << 13;
-        /// The WebAssembly memory64 proposal
-        const MEMORY64 = 1 << 14;
-        /// The WebAssembly extended_const proposal
-        const EXTENDED_CONST = 1 << 15;
+        pub floats: FLOATS(1 << 11) = true;
+        /// The WebAssembly multi memory proposal.
+        pub multi_memory: MULTI_MEMORY(1 << 12) = true;
+        /// The WebAssembly exception handling proposal.
+        pub exceptions: EXCEPTIONS(1 << 13) = false;
+        /// The WebAssembly memory64 proposal.
+        pub memory64: MEMORY64(1 << 14) = false;
+        /// The WebAssembly extended_const proposal.
+        pub extended_const: EXTENDED_CONST(1 << 15) = false;
         /// The WebAssembly component model proposal.
-        const COMPONENT_MODEL = 1 << 16;
-        /// The WebAssembly typed function references proposal
-        const FUNCTION_REFERENCES = 1 << 17;
-        /// The WebAssembly memory control proposal
-        const MEMORY_CONTROL = 1 << 18;
-        /// The WebAssembly gc proposal
-        const GC = 1 << 19;
+        pub component_model: COMPONENT_MODEL(1 << 16) = true;
+        /// The WebAssembly typed function references proposal.
+        pub function_references: FUNCTION_REFERENCES(1 << 17) = false;
+        /// The WebAssembly memory control proposal.
+        pub memory_control: MEMORY_CONTROL(1 << 18) = false;
+        /// The WebAssembly gc proposal.
+        pub gc: GC(1 << 19) = false;
         /// The WebAssembly [custom-page-sizes
         /// proposal](https://github.com/WebAssembly/custom-page-sizes).
-        const CUSTOM_PAGE_SIZE = 1 << 20;
+        pub custom_page_sizes: CUSTOM_PAGE_SIZES(1 << 20) = false;
         /// Support for the `value` type in the component model proposal.
-        const COMPONENT_MODEL_VALUES = 1 << 21;
+        pub component_model_values: COMPONENT_MODEL_VALUES(1 << 21) = false;
         /// Support for the nested namespaces and projects in component model names.
-        const COMPONENT_MODEL_NESTED_NAMES = 1 << 22;
+        pub component_model_nested_names: COMPONENT_MODEL_NESTED_NAMES(1 << 22) = false;
+    }
+}
+
+impl From<WasmFeaturesInflated> for WasmFeatures {
+    #[inline]
+    fn from(inflated: WasmFeaturesInflated) -> Self {
+        Self::from_inflated(inflated)
+    }
+}
+
+impl From<WasmFeatures> for WasmFeaturesInflated {
+    #[inline]
+    fn from(features: WasmFeatures) -> Self {
+        features.inflate()
     }
 }
 
@@ -347,24 +438,6 @@ impl WasmFeatures {
     }
 }
 
-impl Default for WasmFeatures {
-    fn default() -> WasmFeatures {
-        Self::MUTABLE_GLOBAL
-            | Self::SATURATING_FLOAT_TO_INT
-            | Self::SIGN_EXTENSION
-            | Self::REFERENCE_TYPES
-            | Self::MULTI_VALUE
-            | Self::BULK_MEMORY
-            | Self::SIMD
-            | Self::RELAXED_SIMD
-            | Self::THREADS
-            | Self::TAIL_CALL
-            | Self::FLOATS
-            | Self::MULTI_MEMORY
-            | Self::COMPONENT_MODEL
-    }
-}
-
 /// Possible return values from [`Validator::payload`].
 #[allow(clippy::large_enum_variant)]
 pub enum ValidPayload<'a> {
diff --git a/crates/wasmparser/src/validator/core.rs b/crates/wasmparser/src/validator/core.rs
index a71c34b7..5999538f 100644
--- a/crates/wasmparser/src/validator/core.rs
+++ b/crates/wasmparser/src/validator/core.rs
@@ -878,7 +878,7 @@ impl Module {
     ) -> Result<()> {
         self.check_limits(ty.initial, ty.maximum, offset)?;
         let (page_size, page_size_log2) = if let Some(page_size_log2) = ty.page_size_log2 {
-            if !features.contains(WasmFeatures::CUSTOM_PAGE_SIZE) {
+            if !features.contains(WasmFeatures::CUSTOM_PAGE_SIZES) {
                 return Err(BinaryReaderError::new(
                     "the custom page sizes proposal must be enabled to \
                      customize a memory's page size",
diff --git a/crates/wast/Cargo.toml b/crates/wast/Cargo.toml
index ccf7ca77..d197d86e 100644
--- a/crates/wast/Cargo.toml
+++ b/crates/wast/Cargo.toml
@@ -1,6 +1,6 @@
 [package]
 name = "wast"
-version = "203.0.0"
+version = "204.0.0"
 authors = ["Alex Crichton <alex@alexcrichton.com>"]
 edition.workspace = true
 license = "Apache-2.0 WITH LLVM-exception"
diff --git a/crates/wat/Cargo.toml b/crates/wat/Cargo.toml
index 84cebb17..61a7951a 100644
--- a/crates/wat/Cargo.toml
+++ b/crates/wat/Cargo.toml
@@ -1,6 +1,6 @@
 [package]
 name = "wat"
-version = "1.203.0"
+version = "1.204.0"
 authors = ["Alex Crichton <alex@alexcrichton.com>"]
 edition.workspace = true
 license = "Apache-2.0 WITH LLVM-exception"


Test patch:
diff --git a/crates/wasm-smith/tests/common/mod.rs b/crates/wasm-smith/tests/common/mod.rs
index 6aad976a..8a238776 100644
--- a/crates/wasm-smith/tests/common/mod.rs
+++ b/crates/wasm-smith/tests/common/mod.rs
@@ -26,7 +26,7 @@ pub fn parser_features_from_config(config: &Config) -> WasmFeatures {
     features.set(WasmFeatures::FUNCTION_REFERENCES, config.gc_enabled);
     features.set(WasmFeatures::GC, config.gc_enabled);
     features.set(
-        WasmFeatures::CUSTOM_PAGE_SIZE,
+        WasmFeatures::CUSTOM_PAGE_SIZES,
         config.custom_page_sizes_enabled,
     );
     features
diff --git a/tests/roundtrip.rs b/tests/roundtrip.rs
index 519363d6..3929ac5c 100644
--- a/tests/roundtrip.rs
+++ b/tests/roundtrip.rs
@@ -620,7 +620,7 @@ impl TestState {
                     features.insert(WasmFeatures::FUNCTION_REFERENCES);
                     features.insert(WasmFeatures::GC);
                 }
-                "custom-page-sizes" => features.insert(WasmFeatures::CUSTOM_PAGE_SIZE),
+                "custom-page-sizes" => features.insert(WasmFeatures::CUSTOM_PAGE_SIZES),
                 "import-extended.wast" => {
                     features.insert(WasmFeatures::COMPONENT_MODEL_NESTED_NAMES);
                 }