diff options
-rw-r--r-- | crates/ra_ide/src/hover.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_ide/src/hover.rs b/crates/ra_ide/src/hover.rs index d372ca758..24f7eeed3 100644 --- a/crates/ra_ide/src/hover.rs +++ b/crates/ra_ide/src/hover.rs | |||
@@ -156,7 +156,7 @@ fn hover_text_from_name_kind( | |||
156 | 156 | ||
157 | pub(crate) fn hover(db: &RootDatabase, position: FilePosition) -> Option<RangeInfo<HoverResult>> { | 157 | pub(crate) fn hover(db: &RootDatabase, position: FilePosition) -> Option<RangeInfo<HoverResult>> { |
158 | let file = db.parse_or_expand(position.file_id.into())?; | 158 | let file = db.parse_or_expand(position.file_id.into())?; |
159 | let token = file.token_at_offset(position.offset).filter(|it| !it.kind().is_trivia()).next()?; | 159 | let token = file.token_at_offset(position.offset).find(|it| !it.kind().is_trivia())?; |
160 | let token = descend_into_macros(db, position.file_id, token); | 160 | let token = descend_into_macros(db, position.file_id, token); |
161 | 161 | ||
162 | let mut res = HoverResult::new(); | 162 | let mut res = HoverResult::new(); |