diff --git a/src/tools/clippy/src/driver.rs b/src/tools/clippy/src/driver.rs index ee17feed77a00..f1db8d6a3342f 100644 --- a/src/tools/clippy/src/driver.rs +++ b/src/tools/clippy/src/driver.rs @@ -78,7 +78,7 @@ fn track_files(parse_sess: &mut ParseSess) { // Used by `clippy::cargo` lints and to determine the MSRV. `cargo clippy` executes `clippy-driver` // with the current directory set to `CARGO_MANIFEST_DIR` so a relative path is fine if Path::new("Cargo.toml").exists() { - file_depinfo.insert(Symbol::intern("Cargo.toml")); + file_depinfo.insert(std::path::PathBuf::from("Cargo.toml")); } // `clippy.toml` will be automatically tracked as it's loaded with `sess.source_map().load_file()` @@ -93,7 +93,7 @@ fn track_files(parse_sess: &mut ParseSess) { if let Ok(current_exe) = env::current_exe() && let Some(current_exe) = current_exe.to_str() { - file_depinfo.insert(Symbol::intern(current_exe)); + file_depinfo.insert(std::path::PathBuf::from(current_exe)); } } }