Tidy up some documentation comments.
This commit is contained in:
@@ -14,7 +14,7 @@ utility or as a library embedded in a larger application.
|
|||||||
[](https://gitter.im/CraneStation/Lobby)
|
[](https://gitter.im/CraneStation/Lobby)
|
||||||

|

|
||||||
|
|
||||||
*Wasmtime is complete enough to pass the WebAssemlbly spec testsuite.* Support for
|
*Wasmtime is complete enough to pass the WebAssembly spec testsuite.* Support for
|
||||||
system APIs is coming soon!
|
system APIs is coming soon!
|
||||||
|
|
||||||
One goal for this project is to implement [CloudABI](https://cloudabi.org/) using
|
One goal for this project is to implement [CloudABI](https://cloudabi.org/) using
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ use cranelift_entity::PrimaryMap;
|
|||||||
use cranelift_wasm::{DefinedFuncIndex, FuncIndex, WasmError};
|
use cranelift_wasm::{DefinedFuncIndex, FuncIndex, WasmError};
|
||||||
use std::vec::Vec;
|
use std::vec::Vec;
|
||||||
|
|
||||||
/// The result of compiling a WebAssemby module's functions.
|
/// The result of compiling a WebAssembly module's functions.
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
pub struct Compilation {
|
pub struct Compilation {
|
||||||
/// Compiled machine code for the function bodies.
|
/// Compiled machine code for the function bodies.
|
||||||
@@ -35,7 +35,7 @@ pub struct Relocation {
|
|||||||
pub addend: binemit::Addend,
|
pub addend: binemit::Addend,
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Destination function. Can be either user function or some special one, like grow_memory.
|
/// Destination function. Can be either user function or some special one, like `memory.grow`.
|
||||||
#[derive(Debug, Copy, Clone)]
|
#[derive(Debug, Copy, Clone)]
|
||||||
pub enum RelocationTarget {
|
pub enum RelocationTarget {
|
||||||
/// The user function index.
|
/// The user function index.
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ pub fn get_imported_memory32_size_name() -> ir::ExternalName {
|
|||||||
ir::ExternalName::user(1, 3)
|
ir::ExternalName::user(1, 3)
|
||||||
}
|
}
|
||||||
|
|
||||||
/// The FuncEnvironment implementation for use by the `ModuleEnvironment`.
|
/// The `FuncEnvironment` implementation for use by the `ModuleEnvironment`.
|
||||||
pub struct FuncEnvironment<'module_environment> {
|
pub struct FuncEnvironment<'module_environment> {
|
||||||
/// Target-specified configuration.
|
/// Target-specified configuration.
|
||||||
target_config: TargetFrontendConfig,
|
target_config: TargetFrontendConfig,
|
||||||
|
|||||||
@@ -422,7 +422,7 @@ impl Drop for MmapField {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// An Instance of a WebAssemby module.
|
/// An Instance of a WebAssembly module.
|
||||||
///
|
///
|
||||||
/// Note that compiled wasm code passes around raw pointers to `Instance`, so
|
/// Note that compiled wasm code passes around raw pointers to `Instance`, so
|
||||||
/// this shouldn't be moved.
|
/// this shouldn't be moved.
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ use wasmtime_jit::{
|
|||||||
Namespace, RuntimeValue, SetupError,
|
Namespace, RuntimeValue, SetupError,
|
||||||
};
|
};
|
||||||
|
|
||||||
/// Translate from a script::Value to a RuntimeValue.
|
/// Translate from a `script::Value` to a `RuntimeValue`.
|
||||||
fn runtime_value(v: Value) -> RuntimeValue {
|
fn runtime_value(v: Value) -> RuntimeValue {
|
||||||
match v {
|
match v {
|
||||||
Value::I32(x) => RuntimeValue::I32(x),
|
Value::I32(x) => RuntimeValue::I32(x),
|
||||||
|
|||||||
Reference in New Issue
Block a user