diff options
-rw-r--r-- | byterun/ints.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/byterun/ints.c b/byterun/ints.c index 609b93e24..208655fac 100644 --- a/byterun/ints.c +++ b/byterun/ints.c @@ -410,7 +410,10 @@ CAMLprim value int64_of_float(value v) { return copy_int64(I64_of_double(Double_val(v))); } CAMLprim value int64_to_float(value v) -{ return copy_double(I64_to_double(Int64_val(v))); } +{ + int64 i = Int64_val(v); + return copy_double(I64_to_double(i)); +} CAMLprim value int64_of_int32(value v) { return copy_int64(I64_of_int32(Int32_val(v))); } |