doc(c-api) Update documentation for clarity.

This commit is contained in:
Ivan Enderlin
2021-03-05 00:53:24 +01:00
parent 1700c2d056
commit 06a00d9bd0
2 changed files with 6 additions and 6 deletions

View File

@@ -223,9 +223,9 @@ pub extern "C" fn wasmer_metering_points_are_exhausted(instance: &wasm_instance_
///
/// # Example
///
/// This example is pointless as the number of points aren't updated
/// by the WebAssembly module execution, it only illustrates the
/// `wasmer_metering_set_remaining_points` function.
/// This example only illustrates the
/// `wasmer_metering_set_remaining_points` function, as the number of
/// points aren't updated by the WebAssembly module execution
///
/// ```rust
/// # use inline_c::assert_c;
@@ -242,7 +242,7 @@ pub extern "C" fn wasmer_metering_points_are_exhausted(instance: &wasm_instance_
/// }
///
/// int main() {
/// // Set the initial amount of points to 10.
/// // Set the initial amount of points to 7.
/// wasmer_metering_t* metering = wasmer_metering_new(7, cost_function);
///
/// // Consume `metering` to produce `middleware`.

View File

@@ -12,8 +12,8 @@ compile_error!("The `middlewares` feature requires the `compiler` feature to be
/// Opaque representing any kind of middleware.
///
/// It's used by `wasm_config_push_middleware`. A specific middleware
/// is transformed into this type to get a generic middleware. See for
/// Used by `wasm_config_push_middleware`. A specific middleware is
/// transformed into this type to get a generic middleware. See for
/// example
/// [`wasmer_metering_as_middleware`][metering::wasmer_metering_as_middleware].
#[derive(Debug)]