diff options
author | Kirill Bulatov <[email protected]> | 2020-02-18 12:53:02 +0000 |
---|---|---|
committer | Kirill Bulatov <[email protected]> | 2020-02-18 14:03:08 +0000 |
commit | b8ddcb0652f3ec8683023afc1e1f5166d6a712f4 (patch) | |
tree | ea95a1e2083280d84e99f274e5b2b8b269545297 /crates/ra_hir_ty/src/infer/pat.rs | |
parent | eab80cd961919b9321e1d34343ae3f3adb0502e5 (diff) |
Run cargo +nightly fix --clippy -Z unstable-options
Diffstat (limited to 'crates/ra_hir_ty/src/infer/pat.rs')
-rw-r--r-- | crates/ra_hir_ty/src/infer/pat.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_hir_ty/src/infer/pat.rs b/crates/ra_hir_ty/src/infer/pat.rs index a5dfdf6c4..a495ecbfe 100644 --- a/crates/ra_hir_ty/src/infer/pat.rs +++ b/crates/ra_hir_ty/src/infer/pat.rs | |||
@@ -28,7 +28,7 @@ impl<'a, D: HirDatabase> InferenceContext<'a, D> { | |||
28 | 28 | ||
29 | let substs = ty.substs().unwrap_or_else(Substs::empty); | 29 | let substs = ty.substs().unwrap_or_else(Substs::empty); |
30 | 30 | ||
31 | let field_tys = def.map(|it| self.db.field_types(it.into())).unwrap_or_default(); | 31 | let field_tys = def.map(|it| self.db.field_types(it)).unwrap_or_default(); |
32 | 32 | ||
33 | for (i, &subpat) in subpats.iter().enumerate() { | 33 | for (i, &subpat) in subpats.iter().enumerate() { |
34 | let expected_ty = var_data | 34 | let expected_ty = var_data |
@@ -60,7 +60,7 @@ impl<'a, D: HirDatabase> InferenceContext<'a, D> { | |||
60 | 60 | ||
61 | let substs = ty.substs().unwrap_or_else(Substs::empty); | 61 | let substs = ty.substs().unwrap_or_else(Substs::empty); |
62 | 62 | ||
63 | let field_tys = def.map(|it| self.db.field_types(it.into())).unwrap_or_default(); | 63 | let field_tys = def.map(|it| self.db.field_types(it)).unwrap_or_default(); |
64 | for subpat in subpats { | 64 | for subpat in subpats { |
65 | let matching_field = var_data.as_ref().and_then(|it| it.field(&subpat.name)); | 65 | let matching_field = var_data.as_ref().and_then(|it| it.field(&subpat.name)); |
66 | let expected_ty = | 66 | let expected_ty = |