From 10822d76c7b45b9566f8e2b458107ac8b0eac60e Mon Sep 17 00:00:00 2001 From: Son Ho Date: Wed, 2 Aug 2023 18:28:08 +0200 Subject: Make minor modifications --- compiler/Invariants.ml | 3 +++ 1 file changed, 3 insertions(+) (limited to 'compiler/Invariants.ml') diff --git a/compiler/Invariants.ml b/compiler/Invariants.ml index a726eda0..e73c09c4 100644 --- a/compiler/Invariants.ml +++ b/compiler/Invariants.ml @@ -456,6 +456,9 @@ let check_typing_invariant (ctx : C.eval_ctx) : unit = List.iter (fun (v : V.typed_value) -> assert (v.ty = vec_ty)) fvs + | T.Range, [ v0; v1 ], [], [ inner_ty ], [] -> + assert (v0.V.ty = inner_ty); + assert (v1.V.ty = inner_ty) | (T.Array | T.Slice | T.Str), _, _, _, _ -> raise (Failure "Unexpected") | _ -> raise (Failure "Erroneous type")) -- cgit v1.2.3