3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-22 16:45:31 +00:00

ML API bug fixes

This commit is contained in:
Christoph M. Wintersteiger 2016-02-15 12:54:05 +00:00
parent 18c0a3bfaf
commit 62cae4186b
2 changed files with 15 additions and 13 deletions

View file

@ -1456,11 +1456,11 @@ def mk_z3native_stubs_c(ml_dir): # C interface
ml_wrapper.write(' ')
if result != VOID:
ts = type2str(result)
ml_wrapper.write('result = caml_alloc(%s, 0);\n' % ret_size)
if ml_has_plus_type(ts):
ml_wrapper.write(' %s z3rv_m = ' % ts)
ml_wrapper.write('%s z3rv_m = ' % ts)
else:
ml_wrapper.write(' %s z3rv = ' % ts)
ml_wrapper.write('result = caml_alloc(%s, 0);\n ' % ret_size)
ml_wrapper.write('%s z3rv = ' % ts)
elif len(op) != 0:
ml_wrapper.write('result = caml_alloc(%s, 0);\n ' % ret_size)