mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-02 22:54:58 +00:00
Rename Message::Progress::file field to dir
This commit is contained in:
parent
1ceb2ea414
commit
398150827f
3 changed files with 11 additions and 17 deletions
|
@ -586,7 +586,7 @@ impl GlobalState {
|
|||
}
|
||||
}
|
||||
}
|
||||
vfs::loader::Message::Progress { n_total, n_done, file, config_version } => {
|
||||
vfs::loader::Message::Progress { n_total, n_done, dir, config_version } => {
|
||||
always!(config_version <= self.vfs_config_version);
|
||||
|
||||
self.vfs_progress_config_version = config_version;
|
||||
|
@ -603,12 +603,12 @@ impl GlobalState {
|
|||
};
|
||||
|
||||
let mut message = format!("{n_done}/{n_total}");
|
||||
if let Some(file) = file {
|
||||
if let Some(dir) = dir {
|
||||
message += &format!(
|
||||
": {}",
|
||||
match file.strip_prefix(&self.config.root_path()) {
|
||||
match dir.strip_prefix(&self.config.root_path()) {
|
||||
Some(relative_path) => relative_path.as_ref(),
|
||||
None => file.as_ref(),
|
||||
None => dir.as_ref(),
|
||||
}
|
||||
.display()
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue