1 (* Look for assembler errors like this:
2 * 'Warning: 9223372036854775807 shortened to 4294967295'
3 * Try to reproduce and fix.
9 let i = max_int in (* Different on 32 & 64 bit platforms.*)
10 printf "max_int = %d\n" i;
12 printf "min_int = %d\n" i;
13 let i64 = Int64.max_int in (* Same on all platforms. *)
14 printf "Int64.max_int = %Ld\n" i64;
15 let i32 = Int32.max_int in
16 printf "Int32.max_int = %ld\n" i32;
18 (* This is how the stdlib computes min_int:
19 * min_int = 1 lsl (if 1 lsl 31 = 0 (* ie. 32 bit *) then 30 else 62)
21 printf "1 lsl 31 = %d\n" (1 lsl 31);
22 printf "1 lsl 30 = %d\n" (1 lsl 30);
23 printf "1 lsl 62 = %d\n" (1 lsl 62)