mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-27 12:29:21 +00:00
fix: Use original definition ranges for ide_db::search instead of the expanded ranges
This commit is contained in:
parent
e08b3bf70b
commit
6f9de71402
2 changed files with 34 additions and 32 deletions
|
@ -413,6 +413,22 @@ fn foo() {
|
|||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_hl_local_in_attr() {
|
||||
check(
|
||||
r#"
|
||||
//- proc_macros: identity
|
||||
#[proc_macros::identity]
|
||||
fn foo() {
|
||||
let mut bar = 3;
|
||||
// ^^^ write
|
||||
bar$0;
|
||||
// ^^^ read
|
||||
}
|
||||
"#,
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_multi_macro_usage() {
|
||||
check(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue