Cargo Features

[dependencies]
patract-wasmi = { version = "0.9.1", default-features = false, features = ["std", "core", "vec_memory", "reduced-stack-buffer", "errno"] }
default = std

The std feature is set by default whenever patract-wasmi is added without default-features = false somewhere in the dependency tree.

std default = libc

Disable for no_std support

Enables std of downcast-rs, bigint-std and std of num-rational ^0.2.2, std of num-traits, parity-wasm ^0.42.0, and wasmi-validation ^0.4

core = libm, vec_memory

Enable for no_std support

Enables core of wasmi-validation ^0.4

vec_memory core?

Enforce using the linear memory implementation based on Vec instead of mmap on unix systems.

Useful for tests and if you need to minimize unsafe usage at the cost of performance on some workloads.

reduced-stack-buffer

Enables reduced-stack-buffer of parity-wasm ^0.42.0

parity-wasm:

Reduce stack usage for buffered read operations.
This feature is useful when integrating on resource constrained devices such as microcontroler where the stack size is fixed (stacks do not grow) and limited to a few (k)bytes.

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

libm core?
libc std
errno implicit feature

Enables errno ^0.2.4

errno:

Cross-platform interface to the errno variable