Move requires pre validation into the ModuleCodeGenerator

This commit is contained in:
Syrus
2019-12-20 19:32:06 -08:00
parent 303d44cb0f
commit d4e964519d
2 changed files with 12 additions and 15 deletions

View File

@ -646,12 +646,13 @@ impl ModuleCodeGenerator<X64FunctionCode, X64ExecutionContext, CodegenError>
}
}
fn new_with_target(_: Option<String>, _: Option<String>, _: Option<String>) -> Self {
unimplemented!("cross compilation is not available for singlepass backend")
/// Singlepass does validation as it compiles
fn requires_pre_validation(&self) -> bool {
false
}
fn backend_id() -> Backend {
Backend::Singlepass
fn new_with_target(_: Option<String>, _: Option<String>, _: Option<String>) -> Self {
unimplemented!("cross compilation is not available for singlepass backend")
}
fn check_precondition(&mut self, _module_info: &ModuleInfo) -> Result<(), CodegenError> {