wasmtime_environ

Module prelude

source
Expand description

Rust module prelude for Wasmtime crates.

Wasmtime crates that use no_std use core::prelude::* by default which does not include alloc-related functionality such as String and Vec. To have similar ergonomics to std and additionally group up some common functionality this module is intended to be imported at the top of all modules with:

use crate::*;

Externally for crates that depend on wasmtime-environ they should have this in the root of the crate:

use wasmtime_environ::prelude;

and then use crate::* works as usual.

Modules§

  • A contiguous growable array type with heap-allocated contents, written Vec<T>.

Macros§

  • Creates a String using interpolation of runtime expressions.
  • Creates a Vec containing the arguments.

Structs§

  • A pointer type that uniquely owns a heap allocation of type T.
  • A hash table where the iteration order of the key-value pairs is independent of the hash values of the keys.
  • A default set of values.
  • A UTF-8–encoded, growable string.
  • A contiguous growable array type, written as Vec<T>, short for ‘vector’.

Traits§

  • Convenience trait for converting Result<T, E> into anyhow::Result<T>
  • Convenience trait to convert a value into anyhow::Error
  • A generalization of Clone to borrowed data.
  • A trait for converting a value to a String.