mirror of
https://github.com/fluencelabs/wasmer
synced 2025-04-23 17:32:14 +00:00
Fix compile warnings
This commit is contained in:
parent
a7618346e6
commit
b9976f10b7
@ -66,7 +66,7 @@ impl LocalBacking {
|
|||||||
);
|
);
|
||||||
let offset = init.offset;
|
let offset = init.offset;
|
||||||
let mem: &mut LinearMemory = &mut memories[init.memory_index.index()];
|
let mem: &mut LinearMemory = &mut memories[init.memory_index.index()];
|
||||||
let end_of_init = offset + init.data.len();
|
// let end_of_init = offset + init.data.len();
|
||||||
// if end_of_init > mem.current_size() {
|
// if end_of_init > mem.current_size() {
|
||||||
// let grow_pages = (end_of_init / LinearMemory::PAGE_SIZE as usize) + 1;
|
// let grow_pages = (end_of_init / LinearMemory::PAGE_SIZE as usize) + 1;
|
||||||
// mem.grow(grow_pages as u32)
|
// mem.grow(grow_pages as u32)
|
||||||
@ -95,7 +95,7 @@ impl LocalBacking {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// TODO: Actually finish this
|
// TODO: Actually finish this
|
||||||
fn finalize_tables(module: &Module, tables: &mut [TableBacking]) -> Box<[vm::LocalTable]> {
|
fn finalize_tables(_module: &Module, tables: &mut [TableBacking]) -> Box<[vm::LocalTable]> {
|
||||||
tables
|
tables
|
||||||
.iter_mut()
|
.iter_mut()
|
||||||
.map(|table| table.into_vm_table())
|
.map(|table| table.into_vm_table())
|
||||||
|
@ -5,7 +5,7 @@ use crate::runtime::{
|
|||||||
module::{Export, Module},
|
module::{Export, Module},
|
||||||
sig_registry::SigRegistry,
|
sig_registry::SigRegistry,
|
||||||
table::TableBacking,
|
table::TableBacking,
|
||||||
types::{FuncIndex, FuncSig, Memory, Table, Type, Val},
|
types::{FuncSig, Memory, Table, Type, Val},
|
||||||
vm,
|
vm,
|
||||||
};
|
};
|
||||||
use hashbrown::HashMap;
|
use hashbrown::HashMap;
|
||||||
|
@ -145,7 +145,6 @@ impl LinearMemory {
|
|||||||
return None;
|
return None;
|
||||||
}
|
}
|
||||||
|
|
||||||
let prev_bytes = (prev_pages * Self::PAGE_SIZE) as usize;
|
|
||||||
let new_bytes = (new_pages * Self::PAGE_SIZE) as usize;
|
let new_bytes = (new_pages * Self::PAGE_SIZE) as usize;
|
||||||
|
|
||||||
if new_bytes > self.mmap.len() - self.offset_guard_size {
|
if new_bytes > self.mmap.len() - self.offset_guard_size {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user