From 257b8e91e6c66f4dd59166d45f5505142c69c07f Mon Sep 17 00:00:00 2001 From: Brandon Stride <65562702+brandonzstride@users.noreply.github.com> Date: Thu, 29 May 2025 12:06:48 -0400 Subject: [PATCH] Fix out of bounds error in OCaml API (#7665) (#7666) --- src/api/ml/z3.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/ml/z3.ml b/src/api/ml/z3.ml index 0be6e57a0..8f46e551c 100644 --- a/src/api/ml/z3.ml +++ b/src/api/ml/z3.ml @@ -1617,7 +1617,7 @@ struct let g i = Z3native.model_get_const_decl (gc x) x i in List.init (n_funcs + n_consts) (fun i -> if i < n_funcs then f i - else g i + else g (i - n_funcs) ) let eval (x:model) (t:expr) (completion:bool) =