wasmer_version_major

Function wasmer_version_major 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn wasmer_version_major() -> u8
Expand description

Get the major version of the Wasmer C API.

See wasmer_version to learn more.

ยงExample

int main() {
    // Get and check the version components.
    uint8_t version_major = wasmer_version_major();
    uint8_t version_minor = wasmer_version_minor();
    uint8_t version_patch = wasmer_version_patch();

    assert(version_major == WASMER_VERSION_MAJOR);
    assert(version_minor == WASMER_VERSION_MINOR);
    assert(version_patch == WASMER_VERSION_PATCH);

    return 0;
}