aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/infer/pat.rs
diff options
context:
space:
mode:
authorFlorian Diebold <[email protected]>2021-04-04 19:22:00 +0100
committerFlorian Diebold <[email protected]>2021-04-04 19:22:00 +0100
commit508a1ecad3cf9c9f01022b3e95f9d6a7ad7a4cd5 (patch)
tree88f6dd30f03815c04054bb50e302dcd92c8d09c9 /crates/hir_ty/src/infer/pat.rs
parentbc8b27884132a4dbfa019f7d3d5fcbbf9f4912af (diff)
Move things in hir_ty into submodules
- all the types that will be replaced by Chalk go to `types` - `TypeWalk` impls go to `walk`
Diffstat (limited to 'crates/hir_ty/src/infer/pat.rs')
-rw-r--r--crates/hir_ty/src/infer/pat.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/hir_ty/src/infer/pat.rs b/crates/hir_ty/src/infer/pat.rs
index 5b70d5e5a..469f37dd9 100644
--- a/crates/hir_ty/src/infer/pat.rs
+++ b/crates/hir_ty/src/infer/pat.rs
@@ -123,7 +123,7 @@ impl<'a> InferenceContext<'a> {
123 let ty = match &body[pat] { 123 let ty = match &body[pat] {
124 &Pat::Tuple { ref args, ellipsis } => { 124 &Pat::Tuple { ref args, ellipsis } => {
125 let expectations = match expected.as_tuple() { 125 let expectations = match expected.as_tuple() {
126 Some(parameters) => &*parameters.0, 126 Some(parameters) => &*parameters.interned(),
127 _ => &[], 127 _ => &[],
128 }; 128 };
129 129
@@ -239,7 +239,7 @@ impl<'a> InferenceContext<'a> {
239 let (inner_ty, alloc_ty) = match expected.as_adt() { 239 let (inner_ty, alloc_ty) = match expected.as_adt() {
240 Some((adt, subst)) if adt == box_adt => ( 240 Some((adt, subst)) if adt == box_adt => (
241 subst.at(&Interner, 0).assert_ty_ref(&Interner).clone(), 241 subst.at(&Interner, 0).assert_ty_ref(&Interner).clone(),
242 subst.interned(&Interner).get(1).and_then(|a| a.ty(&Interner).cloned()), 242 subst.interned().get(1).and_then(|a| a.ty(&Interner).cloned()),
243 ), 243 ),
244 _ => (self.result.standard_types.unknown.clone(), None), 244 _ => (self.result.standard_types.unknown.clone(), None),
245 }; 245 };