Skip to content

Commit 8747cf8

Browse files
Merge pull request #20835 from ShoyuVanilla/ra-ra
minor: Fix creating `rust-analyzer/rust-analyzer` under target-dir
2 parents 6d4b234 + 26eb637 commit 8747cf8

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

crates/rust-analyzer/src/flycheck.rs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ use cargo_metadata::PackageId;
1212
use crossbeam_channel::{Receiver, Sender, select_biased, unbounded};
1313
use ide_db::FxHashSet;
1414
use itertools::Itertools;
15-
use paths::{AbsPath, AbsPathBuf, Utf8PathBuf};
15+
use paths::{AbsPath, AbsPathBuf, Utf8Path, Utf8PathBuf};
1616
use rustc_hash::FxHashMap;
1717
use serde::Deserialize as _;
1818
use serde_derive::Deserialize;
@@ -432,8 +432,10 @@ impl FlycheckActor {
432432
options
433433
.target_dir
434434
.as_deref()
435-
.unwrap_or("target".as_ref())
436-
.join(format!("rust-analyzer/flycheck{}", self.id)),
435+
.unwrap_or(
436+
Utf8Path::new("target").join("rust-analyzer").as_path(),
437+
)
438+
.join(format!("flycheck{}", self.id)),
437439
),
438440
_ => None,
439441
},

0 commit comments

Comments
 (0)