Skip to main content

ABI_VERSION

Constant ABI_VERSION 

Source
pub const ABI_VERSION: u32 = 4;
Expand description

The revision of the WeaveFFI C ABI this runtime implements.

Every producer exports it as {prefix}_abi_version() (via weaveffi::export_runtime!()), and every generated consumer compares it with the revision it was generated against when it loads the library, turning a silent memory-layout mismatch into a clear error.

The number only changes when the runtime surface (the error layout, the value-buffer encoding, the object or callback-interface conventions, or the set and signatures of the runtime symbols) changes incompatibly. It’s independent of the crate version and of the IDL schema version.

Revision 4 replaced the per-module checksums with per-declaration contract tables, gave callback vtables a size-checked header and every return family (with throws and optional callback parameters), exported {prefix}_alloc on every target (removing {prefix}_dealloc), and added {prefix}_error_set_payload.