module Int:
Int is useful when one is passing unique ids to C and needs a guarantee as to their
representation. Int is always represented as an integer, while Int63 is either an
integer (on 64-bit machines) or a pointer (on 32-bit machines).
The generated ids will therefore be fast to generate and not use much memory. If you do not have very stringent requirements on the size, speed, and ordering of your IDs then you should use the UUIDM library instead, which will give you a truly unique id, even amongst different runs and different machines.
If you do the following:
module Id1 = Int (Unit) module Id2 = Int (Unit)
then the types Id1.t and Id2.t are equivalent. On the other hand, if you do
module Id1 : Id = Int (Unit) module Id2 : Id = Int (Unit)
then the types Id1.t and Id2.t are distinct. Thus, you should use the latter
form.
| Parameters: |
|
type t
include Comparable.S_binable
include Hashable
include Intable
include Stringable
val create : unit -> tcreate.val t_of_sexp : Sexplib.Sexp.t -> tval sexp_of_t : t -> Sexplib.Sexp.tval bin_t : t Bin_prot.Type_class.tval bin_read_t : t Bin_prot.Read_ml.readerval bin_read_t_ : t Bin_prot.Unsafe_read_c.readerval bin_read_t__ : (int -> t) Bin_prot.Unsafe_read_c.readerval bin_reader_t : t Bin_prot.Type_class.readerval bin_size_t : t Bin_prot.Size.sizerval bin_write_t : t Bin_prot.Write_ml.writerval bin_write_t_ : t Bin_prot.Unsafe_write_c.writerval bin_writer_t : t Bin_prot.Type_class.writercreate.