mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 04:44:57 +00:00
Allow navigation targets to be duplicated when the focus range lies in the macro definition site
This commit is contained in:
parent
9b7ec5e31b
commit
9cb13b6efb
38 changed files with 851 additions and 488 deletions
|
@ -58,7 +58,7 @@ fn load_cargo_with_sysroot(
|
|||
&mut {
|
||||
|path| {
|
||||
let len = file_map.len();
|
||||
Some(*file_map.entry(path.to_path_buf()).or_insert(FileId(len as u32)))
|
||||
Some(*file_map.entry(path.to_path_buf()).or_insert(FileId::from_raw(len as u32)))
|
||||
}
|
||||
},
|
||||
&Default::default(),
|
||||
|
@ -142,7 +142,7 @@ fn to_crate_graph(project_workspace: ProjectWorkspace) -> (CrateGraph, ProcMacro
|
|||
let mut counter = 0;
|
||||
move |_path| {
|
||||
counter += 1;
|
||||
Some(FileId(counter))
|
||||
Some(FileId::from_raw(counter))
|
||||
}
|
||||
},
|
||||
&Default::default(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue