The code I wrote here prior was incorrect: a span is present at the level specified and below; previously I thought it was present at the level specified and above. So, previously, a TRACE-level event inside this span would be associated with the module and function name provided here. Now all events inside this span should be associated with it.
wiggle
Wiggle is a code generator for the host side of a witx interface. It is
invoked as a Rust procedural macro.
Wiggle is not specialized to any particular WebAssembly runtime. It is usable in at least Wasmtime and Lucet.
Learning more
Read the docs on docs.rs.
There are child crates for integrating with Wasmtime and Lucet.
The wasi-common crate is implemented using Wiggle and the wasmtime-wasi crate integrates wasi-common with the Wasmtime engine.
Andrew Brown wrote a great blog post on using Wiggle with Wasmtime.