diff options
Diffstat (limited to 'crates/ra_ide/src/inlay_hints.rs')
-rw-r--r-- | crates/ra_ide/src/inlay_hints.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/crates/ra_ide/src/inlay_hints.rs b/crates/ra_ide/src/inlay_hints.rs index f2e4f7ee5..4bbbcd258 100644 --- a/crates/ra_ide/src/inlay_hints.rs +++ b/crates/ra_ide/src/inlay_hints.rs | |||
@@ -2,7 +2,7 @@ use hir::{Adt, Callable, HirDisplay, Semantics, Type}; | |||
2 | use ra_ide_db::RootDatabase; | 2 | use ra_ide_db::RootDatabase; |
3 | use ra_prof::profile; | 3 | use ra_prof::profile; |
4 | use ra_syntax::{ | 4 | use ra_syntax::{ |
5 | ast::{self, ArgListOwner, AstNode, TypeAscriptionOwner}, | 5 | ast::{self, ArgListOwner, AstNode}, |
6 | match_ast, Direction, NodeOrToken, SmolStr, SyntaxKind, TextRange, T, | 6 | match_ast, Direction, NodeOrToken, SmolStr, SyntaxKind, TextRange, T, |
7 | }; | 7 | }; |
8 | use stdx::to_lower_snake_case; | 8 | use stdx::to_lower_snake_case; |
@@ -96,7 +96,7 @@ fn get_chaining_hints( | |||
96 | return None; | 96 | return None; |
97 | } | 97 | } |
98 | 98 | ||
99 | if matches!(expr, ast::Expr::RecordLit(_)) { | 99 | if matches!(expr, ast::Expr::RecordExpr(_)) { |
100 | return None; | 100 | return None; |
101 | } | 101 | } |
102 | 102 | ||
@@ -230,10 +230,10 @@ fn should_not_display_type_hint(db: &RootDatabase, bind_pat: &ast::BindPat, pat_ | |||
230 | match_ast! { | 230 | match_ast! { |
231 | match node { | 231 | match node { |
232 | ast::LetStmt(it) => { | 232 | ast::LetStmt(it) => { |
233 | return it.ascribed_type().is_some() | 233 | return it.ty().is_some() |
234 | }, | 234 | }, |
235 | ast::Param(it) => { | 235 | ast::Param(it) => { |
236 | return it.ascribed_type().is_some() | 236 | return it.ty().is_some() |
237 | }, | 237 | }, |
238 | ast::MatchArm(_it) => { | 238 | ast::MatchArm(_it) => { |
239 | return pat_is_enum_variant(db, bind_pat, pat_ty); | 239 | return pat_is_enum_variant(db, bind_pat, pat_ty); |