From eccc9e66287d5fd141e458ae3ab25ac96a567972 Mon Sep 17 00:00:00 2001 From: Urgau Date: Wed, 23 Aug 2023 15:46:58 +0200 Subject: [RFC 3127 - Trim Paths]: Condition remapped filepath on remap scopes --- compiler/rustc_codegen_llvm/src/coverageinfo/mapgen.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'compiler/rustc_codegen_llvm/src/coverageinfo') diff --git a/compiler/rustc_codegen_llvm/src/coverageinfo/mapgen.rs b/compiler/rustc_codegen_llvm/src/coverageinfo/mapgen.rs index d4e77525698..d58e95fcd36 100644 --- a/compiler/rustc_codegen_llvm/src/coverageinfo/mapgen.rs +++ b/compiler/rustc_codegen_llvm/src/coverageinfo/mapgen.rs @@ -126,9 +126,9 @@ impl GlobalFileTable { // Since rustc generates coverage maps with relative paths, the // compilation directory can be combined with the relative paths // to get absolute paths, if needed. - let working_dir = Symbol::intern( - &tcx.sess.opts.working_dir.remapped_path_if_available().to_string_lossy(), - ); + use rustc_session::RemapFileNameExt; + let working_dir = + Symbol::intern(&tcx.sess.opts.working_dir.for_codegen(&tcx.sess).to_string_lossy()); global_file_table.insert(working_dir); Self { global_file_table } } -- cgit 1.4.1-3-g733a5