mirror of
https://github.com/fluencelabs/wasmer
synced 2024-12-12 22:05:33 +00:00
Fixed middleware linting
This commit is contained in:
parent
5e7a20ef94
commit
a83b6eccfa
@ -134,24 +134,22 @@ mod tests {
|
||||
use super::*;
|
||||
use wabt::wat2wasm;
|
||||
|
||||
use wasmer_runtime_core::codegen::{MiddlewareChain, StreamingCompiler};
|
||||
use wasmer_runtime_core::{backend::Compiler, compile_with, imports, Func};
|
||||
|
||||
#[cfg(feature = "llvm")]
|
||||
fn get_compiler(limit: u64) -> impl Compiler {
|
||||
use wasmer_runtime_core::codegen::{MiddlewareChain, StreamingCompiler};
|
||||
use wasmer_llvm_backend::ModuleCodeGenerator as LLVMMCG;
|
||||
let c: StreamingCompiler<LLVMMCG, _, _, _, _> =
|
||||
StreamingCompiler::new(move || {
|
||||
let mut chain = MiddlewareChain::new();
|
||||
chain.push(Metering::new(limit));
|
||||
chain
|
||||
});
|
||||
let c: StreamingCompiler<LLVMMCG, _, _, _, _> = StreamingCompiler::new(move || {
|
||||
let mut chain = MiddlewareChain::new();
|
||||
chain.push(Metering::new(limit));
|
||||
chain
|
||||
});
|
||||
c
|
||||
}
|
||||
|
||||
#[cfg(feature = "singlepass")]
|
||||
fn get_compiler(limit: u64) -> impl Compiler {
|
||||
use wasmer_runtime_core::codegen::{MiddlewareChain, StreamingCompiler};
|
||||
use wasmer_singlepass_backend::ModuleCodeGenerator as SinglePassMCG;
|
||||
let c: StreamingCompiler<SinglePassMCG, _, _, _, _> = StreamingCompiler::new(move || {
|
||||
let mut chain = MiddlewareChain::new();
|
||||
|
Loading…
Reference in New Issue
Block a user