about summary refs log tree commit diff
path: root/compiler/rustc_interface/src/interface.rs
diff options
context:
space:
mode:
authorMaybe Waffle <waffle.lapkin@gmail.com>2022-11-16 21:58:58 +0000
committerMaybe Waffle <waffle.lapkin@gmail.com>2022-11-16 21:58:58 +0000
commit94470f4efd2ec0786dd1f201e9ea84651b4bb0d0 (patch)
tree1bcf415fa3d0bedc9b223162446ab9653c8f5bec /compiler/rustc_interface/src/interface.rs
parente702534763599db252f2ca308739ec340d0933de (diff)
downloadrust-94470f4efd2ec0786dd1f201e9ea84651b4bb0d0.tar.gz
rust-94470f4efd2ec0786dd1f201e9ea84651b4bb0d0.zip
Use `as_deref` in compiler (but only where it makes sense)
Diffstat (limited to 'compiler/rustc_interface/src/interface.rs')
-rw-r--r--compiler/rustc_interface/src/interface.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_interface/src/interface.rs b/compiler/rustc_interface/src/interface.rs
index 89aaa0b95e4..99c934862c4 100644
--- a/compiler/rustc_interface/src/interface.rs
+++ b/compiler/rustc_interface/src/interface.rs
@@ -304,7 +304,7 @@ pub fn run_compiler<R: Send>(config: Config, f: impl FnOnce(&Compiler) -> R + Se
                 parse_sess_created(&mut sess.parse_sess);
             }
 
-            let temps_dir = sess.opts.unstable_opts.temps_dir.as_ref().map(|o| PathBuf::from(&o));
+            let temps_dir = sess.opts.unstable_opts.temps_dir.as_deref().map(PathBuf::from);
 
             let compiler = Compiler {
                 sess: Lrc::new(sess),