close to working

This commit is contained in:
Lachlan Sneff
2019-02-19 09:58:01 -08:00
parent e381bbd07b
commit 3c7dc200fa
10 changed files with 239 additions and 206 deletions

View File

@ -45,13 +45,6 @@ pub trait Compiler {
#[cfg(feature = "cache")]
unsafe fn from_cache(&self, cache: Cache, _: Token) -> Result<ModuleInner, CacheError>;
#[cfg(feature = "cache")]
fn compile_to_backend_cache_data(
&self,
wasm: &[u8],
_: Token,
) -> CompileResult<(Box<ModuleInfo>, Vec<u8>, Memory)>;
}
/// The functionality exposed by this trait is expected to be used
@ -101,5 +94,5 @@ pub trait FuncResolver: Send + Sync {
}
pub trait CacheGen: Send + Sync {
fn generate_cache(&self, module: &ModuleInner) -> Result<(Box<ModuleInfo>, Box<[u8]>, Memory), CacheError>;
fn generate_cache(&self, module: &ModuleInner) -> Result<(Box<ModuleInfo>, Box<[u8]>, Arc<Memory>), CacheError>;
}