aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir_ty/src')
-rw-r--r--crates/hir_ty/src/infer.rs2
-rw-r--r--crates/hir_ty/src/infer/expr.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/crates/hir_ty/src/infer.rs b/crates/hir_ty/src/infer.rs
index d08867c70..4b683c5a7 100644
--- a/crates/hir_ty/src/infer.rs
+++ b/crates/hir_ty/src/infer.rs
@@ -461,7 +461,7 @@ impl<'a> InferenceContext<'a> {
461 (ty, variant) 461 (ty, variant)
462 } 462 }
463 Some(1) => { 463 Some(1) => {
464 let segment = path.mod_path().segments.last().unwrap(); 464 let segment = path.mod_path().segments().last().unwrap();
465 // this could be an enum variant or associated type 465 // this could be an enum variant or associated type
466 if let Some((AdtId::EnumId(enum_id), _)) = ty.as_adt() { 466 if let Some((AdtId::EnumId(enum_id), _)) = ty.as_adt() {
467 let enum_data = self.db.enum_data(enum_id); 467 let enum_data = self.db.enum_data(enum_id);
diff --git a/crates/hir_ty/src/infer/expr.rs b/crates/hir_ty/src/infer/expr.rs
index d7351d212..12f1591c8 100644
--- a/crates/hir_ty/src/infer/expr.rs
+++ b/crates/hir_ty/src/infer/expr.rs
@@ -137,7 +137,7 @@ impl<'a> InferenceContext<'a> {
137 137
138 self.coerce_merge_branch(&then_ty, &else_ty) 138 self.coerce_merge_branch(&then_ty, &else_ty)
139 } 139 }
140 Expr::Block { statements, tail, label } => match label { 140 Expr::Block { statements, tail, label, id: _ } => match label {
141 Some(_) => { 141 Some(_) => {
142 let break_ty = self.table.new_type_var(); 142 let break_ty = self.table.new_type_var();
143 self.breakables.push(BreakableContext { 143 self.breakables.push(BreakableContext {