diff options
author | Aleksey Kladov <[email protected]> | 2019-09-12 22:34:52 +0100 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2019-09-12 22:34:52 +0100 |
commit | 114a1b878e95c20490af574550ea0825b7a8f9d1 (patch) | |
tree | 3fe7cb05dc4d92d19ecbb87bfafc4a9ff202153e /crates/ra_assists | |
parent | bcf30d389c3744ab517372431eb7e1e1dfcc50df (diff) |
rename AdtDef -> Adt
Diffstat (limited to 'crates/ra_assists')
-rw-r--r-- | crates/ra_assists/src/fill_match_arms.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_assists/src/fill_match_arms.rs b/crates/ra_assists/src/fill_match_arms.rs index cc3879562..543ed164c 100644 --- a/crates/ra_assists/src/fill_match_arms.rs +++ b/crates/ra_assists/src/fill_match_arms.rs | |||
@@ -1,6 +1,6 @@ | |||
1 | use std::iter; | 1 | use std::iter; |
2 | 2 | ||
3 | use hir::{db::HirDatabase, AdtDef, HasSource}; | 3 | use hir::{db::HirDatabase, Adt, HasSource}; |
4 | use ra_syntax::ast::{self, AstNode, NameOwner}; | 4 | use ra_syntax::ast::{self, AstNode, NameOwner}; |
5 | 5 | ||
6 | use crate::{ast_editor::AstBuilder, Assist, AssistCtx, AssistId}; | 6 | use crate::{ast_editor::AstBuilder, Assist, AssistCtx, AssistId}; |
@@ -60,7 +60,7 @@ fn resolve_enum_def( | |||
60 | let expr_ty = analyzer.type_of(db, &expr)?; | 60 | let expr_ty = analyzer.type_of(db, &expr)?; |
61 | 61 | ||
62 | analyzer.autoderef(db, expr_ty).find_map(|ty| match ty.as_adt() { | 62 | analyzer.autoderef(db, expr_ty).find_map(|ty| match ty.as_adt() { |
63 | Some((AdtDef::Enum(e), _)) => Some(e.source(db).ast), | 63 | Some((Adt::Enum(e), _)) => Some(e.source(db).ast), |
64 | _ => None, | 64 | _ => None, |
65 | }) | 65 | }) |
66 | } | 66 | } |