From 45f4a1e559f11054fd567be24d91b5559b76a397 Mon Sep 17 00:00:00 2001 From: Jonas Schievink Date: Fri, 21 May 2021 21:08:06 +0200 Subject: Remove `StructDefKind` --- crates/hir_def/src/nameres/collector.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'crates/hir_def/src/nameres') diff --git a/crates/hir_def/src/nameres/collector.rs b/crates/hir_def/src/nameres/collector.rs index fa4b135fd..9b108bfe7 100644 --- a/crates/hir_def/src/nameres/collector.rs +++ b/crates/hir_def/src/nameres/collector.rs @@ -27,8 +27,8 @@ use crate::{ intern::Interned, item_scope::{ImportType, PerNsGlobImports}, item_tree::{ - self, FileItemTreeId, ItemTree, ItemTreeId, MacroCall, MacroDef, MacroRules, Mod, ModItem, - ModKind, StructDefKind, + self, Fields, FileItemTreeId, ItemTree, ItemTreeId, MacroCall, MacroDef, MacroRules, Mod, + ModItem, ModKind, }, macro_call_as_call_id, nameres::{ @@ -1281,7 +1281,7 @@ impl ModCollector<'_, '_> { .into(), name: &it.name, visibility: &self.item_tree[it.visibility], - has_constructor: it.kind != StructDefKind::Record, + has_constructor: !matches!(it.fields, Fields::Record(_)), }); } ModItem::Union(id) => { -- cgit v1.2.3