fix(wasmtime):Config methods should be idempotent (#4252)
This commit refactored `Config` to use a seperate `CompilerConfig` field instead of operating on `CompilerBuilder` directly to make all its methods idempotent. Fixes #4189
This commit is contained in:
@@ -76,9 +76,6 @@ pub enum CompileError {
|
||||
/// This is used in Wasmtime to separate compiler implementations, currently
|
||||
/// mostly used to separate Cranelift from Wasmtime itself.
|
||||
pub trait CompilerBuilder: Send + Sync + fmt::Debug {
|
||||
/// Like the `Clone` trait, but for the boxed trait object.
|
||||
fn clone(&self) -> Box<dyn CompilerBuilder>;
|
||||
|
||||
/// Sets the target of compilation to the target specified.
|
||||
fn target(&mut self, target: target_lexicon::Triple) -> Result<()>;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user