rename PassiveElemIndex to ElemIndex and same for PassiveDataIndex (#1188)
* rename PassiveElemIndex to ElemIndex and same for PassiveDataIndex (#1411) * rename PassiveDataIndex to DataIndex * rename PassiveElemIndex to ElemIndex * Apply renamings to wasmtime as well * Run rustfmt Co-authored-by: csmoe <csmoe@msn.com>
This commit is contained in:
@@ -11,8 +11,8 @@ use crate::environ::{
|
||||
use crate::func_translator::FuncTranslator;
|
||||
use crate::state::ModuleTranslationState;
|
||||
use crate::translation_utils::{
|
||||
DefinedFuncIndex, FuncIndex, Global, GlobalIndex, Memory, MemoryIndex, PassiveDataIndex,
|
||||
PassiveElemIndex, SignatureIndex, Table, TableIndex,
|
||||
DataIndex, DefinedFuncIndex, ElemIndex, FuncIndex, Global, GlobalIndex, Memory, MemoryIndex,
|
||||
SignatureIndex, Table, TableIndex,
|
||||
};
|
||||
use core::convert::TryFrom;
|
||||
use cranelift_codegen::cursor::FuncCursor;
|
||||
@@ -607,7 +607,7 @@ impl<'data> ModuleEnvironment<'data> for DummyEnvironment {
|
||||
|
||||
fn declare_passive_element(
|
||||
&mut self,
|
||||
_elem_index: PassiveElemIndex,
|
||||
_elem_index: ElemIndex,
|
||||
_segments: Box<[FuncIndex]>,
|
||||
) -> WasmResult<()> {
|
||||
Ok(())
|
||||
@@ -615,7 +615,7 @@ impl<'data> ModuleEnvironment<'data> for DummyEnvironment {
|
||||
|
||||
fn declare_passive_data(
|
||||
&mut self,
|
||||
_elem_index: PassiveDataIndex,
|
||||
_elem_index: DataIndex,
|
||||
_segments: &'data [u8],
|
||||
) -> WasmResult<()> {
|
||||
Ok(())
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
|
||||
use crate::state::{FuncTranslationState, ModuleTranslationState};
|
||||
use crate::translation_utils::{
|
||||
FuncIndex, Global, GlobalIndex, Memory, MemoryIndex, PassiveDataIndex, PassiveElemIndex,
|
||||
SignatureIndex, Table, TableIndex,
|
||||
DataIndex, ElemIndex, FuncIndex, Global, GlobalIndex, Memory, MemoryIndex, SignatureIndex,
|
||||
Table, TableIndex,
|
||||
};
|
||||
use core::convert::From;
|
||||
use cranelift_codegen::cursor::FuncCursor;
|
||||
@@ -606,7 +606,7 @@ pub trait ModuleEnvironment<'data>: TargetEnvironment {
|
||||
/// Declare a passive element segment.
|
||||
fn declare_passive_element(
|
||||
&mut self,
|
||||
index: PassiveElemIndex,
|
||||
index: ElemIndex,
|
||||
elements: Box<[FuncIndex]>,
|
||||
) -> WasmResult<()>;
|
||||
|
||||
@@ -620,11 +620,7 @@ pub trait ModuleEnvironment<'data>: TargetEnvironment {
|
||||
}
|
||||
|
||||
/// Declare a passive data segment.
|
||||
fn declare_passive_data(
|
||||
&mut self,
|
||||
data_index: PassiveDataIndex,
|
||||
data: &'data [u8],
|
||||
) -> WasmResult<()>;
|
||||
fn declare_passive_data(&mut self, data_index: DataIndex, data: &'data [u8]) -> WasmResult<()>;
|
||||
|
||||
/// Provides the contents of a function body.
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user