aboutsummaryrefslogtreecommitdiff
path: root/crates/hir/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir/src')
-rw-r--r--crates/hir/src/code_model.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/hir/src/code_model.rs b/crates/hir/src/code_model.rs
index fc1a74641..7656db974 100644
--- a/crates/hir/src/code_model.rs
+++ b/crates/hir/src/code_model.rs
@@ -1700,7 +1700,7 @@ impl Type {
1700 1700
1701 pub fn is_packed(&self, db: &dyn HirDatabase) -> bool { 1701 pub fn is_packed(&self, db: &dyn HirDatabase) -> bool {
1702 let adt_id = match self.ty.value { 1702 let adt_id = match self.ty.value {
1703 Ty::Adt(adt_id, ..) => adt_id, 1703 Ty::Adt(hir_ty::AdtId(adt_id), ..) => adt_id,
1704 _ => return false, 1704 _ => return false,
1705 }; 1705 };
1706 1706
@@ -1728,8 +1728,8 @@ impl Type {
1728 1728
1729 pub fn fields(&self, db: &dyn HirDatabase) -> Vec<(Field, Type)> { 1729 pub fn fields(&self, db: &dyn HirDatabase) -> Vec<(Field, Type)> {
1730 let (variant_id, substs) = match self.ty.value { 1730 let (variant_id, substs) = match self.ty.value {
1731 Ty::Adt(AdtId::StructId(s), ref substs) => (s.into(), substs), 1731 Ty::Adt(hir_ty::AdtId(AdtId::StructId(s)), ref substs) => (s.into(), substs),
1732 Ty::Adt(AdtId::UnionId(u), ref substs) => (u.into(), substs), 1732 Ty::Adt(hir_ty::AdtId(AdtId::UnionId(u)), ref substs) => (u.into(), substs),
1733 _ => return Vec::new(), 1733 _ => return Vec::new(),
1734 }; 1734 };
1735 1735