Move start_index out of TranslationResult and into the WasmRuntime.
This makes it more consistent with how all the rest of the content of a wasm module is handled. And, now TranslationResult just has a Vec of translated functions, which will make it easier to refactor further.
This commit is contained in:
@@ -189,6 +189,10 @@ pub trait WasmRuntime: FuncEnvironment {
|
||||
offset: usize,
|
||||
data: &[u8],
|
||||
) -> Result<(), String>;
|
||||
|
||||
/// Declares a start function.
|
||||
fn declare_start_func(&mut self, index: FunctionIndex);
|
||||
|
||||
/// Call this function after having declared all the runtime elements but prior to the
|
||||
/// function body translation.
|
||||
fn begin_translation(&mut self);
|
||||
|
||||
Reference in New Issue
Block a user