aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
authorLaurenČ›iu Nicola <[email protected]>2020-12-30 09:37:52 +0000
committerLaurenČ›iu Nicola <[email protected]>2020-12-30 09:37:52 +0000
commitfbeccf0b9d179bdaa3ddaf80f4e517a35f747124 (patch)
tree358e83c85277d3b263f846be31fc32ab64c72968 /crates
parent386c447038166687b9403bec71d5924b8e2d3fbc (diff)
Allow spurious warning from rust-lang/rust#80501
Diffstat (limited to 'crates')
-rw-r--r--crates/hir_ty/src/infer/expr.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/crates/hir_ty/src/infer/expr.rs b/crates/hir_ty/src/infer/expr.rs
index 70a3f3075..f2fc69b2f 100644
--- a/crates/hir_ty/src/infer/expr.rs
+++ b/crates/hir_ty/src/infer/expr.rs
@@ -648,6 +648,8 @@ impl<'a> InferenceContext<'a> {
648 } 648 }
649 Expr::Array(array) => { 649 Expr::Array(array) => {
650 let elem_ty = match &expected.ty { 650 let elem_ty = match &expected.ty {
651 // FIXME: remove when https://github.com/rust-lang/rust/issues/80501 is fixed
652 #[allow(unreachable_patterns)]
651 ty_app!(TypeCtor::Array, st) | ty_app!(TypeCtor::Slice, st) => { 653 ty_app!(TypeCtor::Array, st) | ty_app!(TypeCtor::Slice, st) => {
652 st.as_single().clone() 654 st.as_single().clone()
653 } 655 }