diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2020-02-28 15:56:07 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2020-02-28 15:56:07 +0000 |
commit | c692e07b4ff648fea742c53c0dbad57d6f652068 (patch) | |
tree | d186df8fb298272eaa4ce14d2fccc854413bc566 /crates/ra_ide/src/references.rs | |
parent | 93f632ca4e7bb7fd54830e456d629a4948a92337 (diff) | |
parent | 56ce34c6a7ec0b4426d4cb25e10512c7efaf6f06 (diff) |
Merge #3367
3367: Fix highlighting of const patterns r=matklad a=matklad
bors r+
🤖
Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/ra_ide/src/references.rs')
-rw-r--r-- | crates/ra_ide/src/references.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_ide/src/references.rs b/crates/ra_ide/src/references.rs index baa8a4d29..f763013ae 100644 --- a/crates/ra_ide/src/references.rs +++ b/crates/ra_ide/src/references.rs | |||
@@ -155,7 +155,7 @@ fn find_name( | |||
155 | opt_name: Option<ast::Name>, | 155 | opt_name: Option<ast::Name>, |
156 | ) -> Option<RangeInfo<(String, NameDefinition)>> { | 156 | ) -> Option<RangeInfo<(String, NameDefinition)>> { |
157 | if let Some(name) = opt_name { | 157 | if let Some(name) = opt_name { |
158 | let def = classify_name(sema, &name)?; | 158 | let def = classify_name(sema, &name)?.definition(); |
159 | let range = name.syntax().text_range(); | 159 | let range = name.syntax().text_range(); |
160 | return Some(RangeInfo::new(range, (name.text().to_string(), def))); | 160 | return Some(RangeInfo::new(range, (name.text().to_string(), def))); |
161 | } | 161 | } |