about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbjorn3 <bjorn3@users.noreply.github.com>2022-04-30 20:51:17 +0200
committerbjorn3 <bjorn3@users.noreply.github.com>2022-04-30 20:51:17 +0200
commite2f645dd7f98ea47c291cdd3c7ca55771c8c26d3 (patch)
tree4b4d3492a1f400e798c2a4c7769889e73dbd7f7e
parent758a7da13bc253783847d75c52f6118e40d8276c (diff)
downloadrust-e2f645dd7f98ea47c291cdd3c7ca55771c8c26d3.tar.gz
rust-e2f645dd7f98ea47c291cdd3c7ca55771c8c26d3.zip
Let LtoModuleCodegen::optimize take self by value
-rw-r--r--src/lib.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib.rs b/src/lib.rs
index 2b960582879..72da59a1bf8 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -213,7 +213,7 @@ impl WriteBackendMethods for GccCodegenBackend {
                     unimplemented!();
                 }
             };
-        Ok(LtoModuleCodegen::Fat { module: Some(module), _serialized_bitcode: vec![] })
+        Ok(LtoModuleCodegen::Fat { module, _serialized_bitcode: vec![] })
     }
 
     fn run_thin_lto(_cgcx: &CodegenContext<Self>, _modules: Vec<(String, Self::ThinBuffer)>, _cached_modules: Vec<(SerializedModule<Self::ModuleBuffer>, WorkProduct)>) -> Result<(Vec<LtoModuleCodegen<Self>>, Vec<WorkProduct>), FatalError> {
@@ -234,7 +234,7 @@ impl WriteBackendMethods for GccCodegenBackend {
         Ok(())
     }
 
-    unsafe fn optimize_thin(_cgcx: &CodegenContext<Self>, _thin: &mut ThinModule<Self>) -> Result<ModuleCodegen<Self::Module>, FatalError> {
+    unsafe fn optimize_thin(_cgcx: &CodegenContext<Self>, _thin: ThinModule<Self>) -> Result<ModuleCodegen<Self::Module>, FatalError> {
         unimplemented!();
     }