diff options
author | Laurențiu Nicola <[email protected]> | 2021-06-18 12:40:51 +0100 |
---|---|---|
committer | Laurențiu Nicola <[email protected]> | 2021-06-18 12:40:51 +0100 |
commit | e3ce88f6f25901b1d33fbc5f931a9d8f90b9e2b8 (patch) | |
tree | c6876d5f81bafe5d405f7ab72ff61e4a748a3bc5 /crates/ide | |
parent | 0d863ccea96c6c3256fad12807a0eedbfccd8294 (diff) |
Minor clippy perf fixes
Diffstat (limited to 'crates/ide')
-rw-r--r-- | crates/ide/src/goto_type_definition.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ide/src/goto_type_definition.rs b/crates/ide/src/goto_type_definition.rs index ca3c02bf6..43cffefe5 100644 --- a/crates/ide/src/goto_type_definition.rs +++ b/crates/ide/src/goto_type_definition.rs | |||
@@ -25,7 +25,7 @@ pub(crate) fn goto_type_definition( | |||
25 | let token: SyntaxToken = pick_best(file.syntax().token_at_offset(position.offset))?; | 25 | let token: SyntaxToken = pick_best(file.syntax().token_at_offset(position.offset))?; |
26 | let token: SyntaxToken = sema.descend_into_macros(token); | 26 | let token: SyntaxToken = sema.descend_into_macros(token); |
27 | 27 | ||
28 | let (ty, node) = sema.token_ancestors_with_macros(token.clone()).find_map(|node| { | 28 | let (ty, node) = sema.token_ancestors_with_macros(token).find_map(|node| { |
29 | let ty = match_ast! { | 29 | let ty = match_ast! { |
30 | match node { | 30 | match node { |
31 | ast::Expr(it) => sema.type_of_expr(&it)?, | 31 | ast::Expr(it) => sema.type_of_expr(&it)?, |