add track_path::path fn for usage in proc_macros by drahnr · Pull Request #84029 · rust-lang/rust (original) (raw)

Diff in /checkout/compiler/rustc_interface/src/passes.rs at line 28:
 use rustc_plugin_impl as plugin;
 use rustc_query_impl::Queries as TcxQueries;
 use rustc_resolve::{Resolver, ResolverArenas};
+use rustc_serialize::json;
 use rustc_session::config::{CrateType, Input, OutputFilenames, OutputType, PpMode, PpSourceMode};
 use rustc_session::lint;
 use rustc_session::output::{filename_for_input, filename_for_metadata};
Diff in /checkout/compiler/rustc_interface/src/passes.rs at line 37:
 use rustc_span::FileName;
 use rustc_trait_selection::traits;
 use rustc_typeck as typeck;
-use tracing::{info, warn};
-use rustc_serialize::json;
 use tempfile::Builder as TempFileBuilder;
+use tracing::{info, warn};
 
 use std::any::Any;
 use std::cell::RefCell;
Diff in /checkout/compiler/rustc_interface/src/passes.rs at line 597:
         // Account for explicitly marked-to-track files
         // (e.g. accessed in proc macros).
         let file_depinfo = sess.parse_sess.file_depinfo.borrow();
-        let extra_tracked_files = file_depinfo
-            .iter()
-            .map(|path_sym| {
-                let path = PathBuf::from(&*path_sym.as_str());
-                let file = FileName::from(path);
-                escape_dep_filename(&file.prefer_local().to_string())
-            });
+        let extra_tracked_files = file_depinfo.iter().map(|path_sym| {
+            let path = PathBuf::from(&*path_sym.as_str());
+            let file = FileName::from(path);
+            escape_dep_filename(&file.prefer_local().to_string())
+        });
         files.extend(extra_tracked_files);
 
         if let Some(ref backend) = sess.opts.debugging_opts.codegen_backend {
Running `"/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/rustfmt" "--config-path" "/checkout" "--edition" "2018" "--unstable-features" "--skip-children" "--check" "/checkout/compiler/rustc_target/src/abi/call/x86_win64.rs" "/checkout/compiler/rustc_interface/src/proc_macro_decls.rs" "/checkout/compiler/rustc_target/src/abi/call/msp430.rs" "/checkout/compiler/rustc_interface/src/passes.rs" "/checkout/compiler/rustc_target/src/abi/call/powerpc.rs" "/checkout/compiler/rustc_target/src/abi/call/sparc64.rs"` failed.
If you're running `tidy`, try again with `--bless`. Or, if you just want to format code, run `./x.py fmt` instead.