From e548e6f8fc15abeacf44bac6a970c8ed974246b0 Mon Sep 17 00:00:00 2001 From: Lucas Franceschino Date: Tue, 21 May 2024 14:13:57 +0200 Subject: [PATCH] fix(exporter): fixes #680 --- frontend/exporter/src/types/mir.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/frontend/exporter/src/types/mir.rs b/frontend/exporter/src/types/mir.rs index a4d7476bb..99c3c042f 100644 --- a/frontend/exporter/src/types/mir.rs +++ b/frontend/exporter/src/types/mir.rs @@ -762,7 +762,8 @@ impl<'tcx, S: UnderOwnerState<'tcx> + HasMir<'tcx>> SInto min_length, from_end, } => { - let TyKind::Slice(ty) = current_ty.kind() else { + let (TyKind::Slice(ty) | TyKind::Array(ty, _)) = current_ty.kind() + else { supposely_unreachable_fatal!( s, "PlaceConstantIndexNotSlice"; {current_ty, current_kind, elem}