Cargo Features

cranelift-module = { version = "0.105.2", default-features = false, features = ["std", "core", "enable-serde"] }
default = std

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

std default

Enables cranelift-codegen


The "std" feature enables use of libstd. The "core" feature enables use of some minimal std-like replacement libraries. At least one of these two features need to be enabled.

core = hashbrown

Enables core of cranelift-codegen


The "core" feature used to enable a hashmap workaround, but is now deprecated (we (i) always use hashbrown, and (ii) don't support a no_std build anymore). The feature remains for backward compatibility as a no-op.

enable-serde = serde, serde_derive

For dependent crates that want to serialize some parts of cranelift

Enables enable-serde of cranelift-codegen

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features.

hashbrown core?
serde enable-serde?
serde_derive enable-serde?