3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-06-27 08:28:44 +00:00

Fix out of bounds error in OCaml API (#7665) (#7666)

This commit is contained in:
Brandon Stride 2025-05-29 12:06:48 -04:00 committed by GitHub
parent 4b2e5adc11
commit 257b8e91e6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1617,7 +1617,7 @@ struct
let g i = Z3native.model_get_const_decl (gc x) x i in let g i = Z3native.model_get_const_decl (gc x) x i in
List.init (n_funcs + n_consts) (fun i -> List.init (n_funcs + n_consts) (fun i ->
if i < n_funcs then f i if i < n_funcs then f i
else g i else g (i - n_funcs)
) )
let eval (x:model) (t:expr) (completion:bool) = let eval (x:model) (t:expr) (completion:bool) =