]> git.lizzy.rs Git - rust.git/commitdiff
Fix run-make-fulldeps test
authorOli Scherer <git-spam-no-reply9815368754983@oli-obk.de>
Fri, 13 Jan 2023 15:19:25 +0000 (15:19 +0000)
committerOli Scherer <git-spam-no-reply9815368754983@oli-obk.de>
Mon, 16 Jan 2023 14:46:44 +0000 (14:46 +0000)
tests/run-make-fulldeps/issue-19371/foo.rs

index 7e1b6aeb31558c30da283cc004473e47c7e2bca3..5bb38fc02af91be94cf296b3c6358341d0b6eb23 100644 (file)
@@ -1,12 +1,12 @@
 #![feature(rustc_private)]
 
-extern crate rustc_interface;
 extern crate rustc_driver;
+extern crate rustc_interface;
 extern crate rustc_session;
 extern crate rustc_span;
 
-use rustc_session::config::{Input, Options, OutputType, OutputTypes};
 use rustc_interface::interface;
+use rustc_session::config::{Input, Options, OutputType, OutputTypes};
 use rustc_span::source_map::FileName;
 
 use std::path::PathBuf;
@@ -50,7 +50,6 @@ fn compile(code: String, output: PathBuf, sysroot: PathBuf) {
         crate_cfg: Default::default(),
         crate_check_cfg: Default::default(),
         input,
-        input_path: None,
         output_file: Some(output),
         output_dir: None,
         file_loader: None,
@@ -64,9 +63,7 @@ fn compile(code: String, output: PathBuf, sysroot: PathBuf) {
 
     interface::run_compiler(config, |compiler| {
         // This runs all the passes prior to linking, too.
-        let linker = compiler.enter(|queries| {
-            queries.linker()
-        });
+        let linker = compiler.enter(|queries| queries.linker());
         if let Ok(linker) = linker {
             linker.link();
         }