]> git.lizzy.rs Git - rust.git/blobdiff - src/tools/clippy/clippy_lints/src/large_const_arrays.rs
Auto merge of #78420 - estebank:suggest-assoc-fn, r=petrochenkov
[rust.git] / src / tools / clippy / clippy_lints / src / large_const_arrays.rs
index c6cc174a8c97b28b6203a684e729d7dfd599aa42..025ff86da39d8cc9fd6b117fce951e37f400ebcd 100644 (file)
@@ -51,7 +51,7 @@ fn check_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx Item<'_>) {
             if !item.span.from_expansion();
             if let ItemKind::Const(hir_ty, _) = &item.kind;
             let ty = hir_ty_to_ty(cx.tcx, hir_ty);
-            if let ty::Array(element_type, cst) = ty.kind;
+            if let ty::Array(element_type, cst) = ty.kind();
             if let ConstKind::Value(val) = cst.val;
             if let ConstValue::Scalar(element_count) = val;
             if let Ok(element_count) = element_count.to_machine_usize(&cx.tcx);