pub trait SectionType:
Debug
+ PartialEq
+ Eq
+ PartialOrd
+ Ord {
// Required method
fn allow_grouping(&self) -> bool;
}
Expand description
Section type defines the type of a section in a WASM binary
This is used to group sections by their type (for example to get all the functions in a module) and also to determine whether a given section type supports grouping.
Required Methods§
Sourcefn allow_grouping(&self) -> bool
fn allow_grouping(&self) -> bool
If a section type supports grouping, then sections of the same type next to each other will be serialized into a single WASM section containing multiple elements when writing out a WASM binary.
Some section types does not support this encoding (such as the core::Start or core::Custom sections), in these cases they are all serialized into their own section.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.