aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty
diff options
context:
space:
mode:
authorMatthias Krüger <[email protected]>2021-03-21 12:13:34 +0000
committerMatthias Krüger <[email protected]>2021-03-21 12:13:34 +0000
commitae7e55c1dd801c60092205ec8890179e10a47814 (patch)
tree7e55e7a0c144610d55509b3e28bde0edf0953e39 /crates/hir_ty
parentbd407a9882250cbbb0897faba08e7d5ef80a4862 (diff)
clippy::complexity simplifications related to Iterators
Diffstat (limited to 'crates/hir_ty')
-rw-r--r--crates/hir_ty/src/infer/pat.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/hir_ty/src/infer/pat.rs b/crates/hir_ty/src/infer/pat.rs
index befa0d69b..ec491648f 100644
--- a/crates/hir_ty/src/infer/pat.rs
+++ b/crates/hir_ty/src/infer/pat.rs
@@ -38,7 +38,7 @@ impl<'a> InferenceContext<'a> {
38 let field_tys = def.map(|it| self.db.field_types(it)).unwrap_or_default(); 38 let field_tys = def.map(|it| self.db.field_types(it)).unwrap_or_default();
39 let (pre, post) = match ellipsis { 39 let (pre, post) = match ellipsis {
40 Some(idx) => subpats.split_at(idx), 40 Some(idx) => subpats.split_at(idx),
41 None => (&subpats[..], &[][..]), 41 None => (subpats, &[][..]),
42 }; 42 };
43 let post_idx_offset = field_tys.iter().count() - post.len(); 43 let post_idx_offset = field_tys.iter().count() - post.len();
44 44