From a27ac524268c7490a9c5f6ee147806ad1eba98bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Bobot?= <francois.bobot@cea.fr> Date: Sun, 19 Jun 2022 19:00:26 +0200 Subject: [PATCH] Support 32bit by removing large integer constant --- CHANGES | 2 ++ src_colibri2/bin/options.ml | 5 ++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/CHANGES b/CHANGES index eb66a829c..e11b4d691 100644 --- a/CHANGES +++ b/CHANGES @@ -1,7 +1,9 @@ ## Release 0.3.3 * Bump cmdliner version + * Bump OCaml version * Remove some warnings in 4.14 * Fix OUnit2 dependency + * Support 32bit by removing large integer constant ## Release 0.3.2 * Add missing dependencies diff --git a/src_colibri2/bin/options.ml b/src_colibri2/bin/options.ml index 25d5c0de9..612bc1caa 100644 --- a/src_colibri2/bin/options.ml +++ b/src_colibri2/bin/options.ml @@ -195,13 +195,12 @@ let print_limit_last_effort : _ Arg.printer = let size_string f = let n = int_of_float f in let aux n div = (n / div, n mod div) in - let n_tera, n = aux n 1_000_000_000_000 in let n_giga, n = aux n 1_000_000_000 in let n_mega, n = aux n 1_000_000 in let n_kilo, n = aux n 1_000 in let print_aux s n = if n <> 0 then string_of_int n ^ s else "" in - print_aux "To" n_tera ^ print_aux "Go" n_giga ^ print_aux "Mo" n_mega - ^ print_aux "ko" n_kilo ^ print_aux "" n + print_aux "Go" n_giga ^ print_aux "Mo" n_mega ^ print_aux "ko" n_kilo + ^ print_aux "" n let print_size fmt f = Format.fprintf fmt "%s" (size_string f) -- GitLab