package integers
All checked builds passInstall
dune-project
Dependency
Authors
Maintainers
Sources
sha256=04a1a6d5cc1ecfd3f354a83caed27e59995bb26adec64d88193ccc36268929fa
md5=5155b252a1143ebe7f895003a7103f5e
Description
Added to opam-repository:
README
ocaml-integers
The ocaml-integers library provides a number of 8-, 16-, 32- and 64-bit signed and unsigned integer types, together with aliases such as long and size_t whose sizes depend on the host platform.
Features
The interfaces follow the pattern of the signatures of the
Int32,Int64, andNativeintmodules in the OCaml standard library.The behaviour also follows the standard library; for example, conversions such as
of_inttruncate, and operations are "modulo" in general:# Unsigned.UInt8.(pred zero);; - : Unsigned.UInt8.t = <uint8 255>Top-level printers for each type are included
# Unsigned.UInt32.[of_int 103; one; of_string "1000"];; - : Unsigned.UInt32.t list = [<uint32 103>; <uint32 1>; <uint32 1000>]Infix operators are available:
# Unsigned.UInt32.(Infix.(one + one));; - : Unsigned.UInt32.t = <uint32 2>Polymorphic operations such as comparison behave correctly:
# open Unsigned.UInt32 # zero < one;; - : bool = true # max_int < zero;; - : bool = falseIntegers 32 bits and above are boxed; integers below 32 bits are unboxed.
# Obj.(tag (repr Unsigned.UInt32.zero));; - : int = 255 # Obj.(tag (repr Unsigned.UInt16.zero));; - : int = 1000
Using integers with js_of_ocaml
The integers_stubs_js package provides JavaScript stubs that make it possible to use this library with js_of_ocaml
Dependencies (3)
- stdlib-shims
-
dune
>= "1.0" -
ocaml
>= "4.03"
Dev Dependencies
None
Used by (30)
-
bls12-381
>= "3.0.0" -
bls12-381-unix
>= "1.1.0" -
caqti-driver-mariadb
>= "3.0.1" - class_group_vdf
-
ctypes
>= "0.15.0" -
ctypes-foreign
>= "0.21.1" -
extism
>= "1.1.0" - llama-cpp-ocaml
-
luv
>= "0.5.13" - nsq
-
nx
< "1.0.0~alpha1" - object
-
ocgtk
< "0.1~preview2" - owi
-
owl-base
= "0.7.0" - pb
- pb-plugin
-
pkcs11
>= "1.0.1" - posix-base
-
ppx_cstubs
>= "0.5.0.2" & < "0.6.0" | >= "0.6.1.2" - quickjs
- randii
-
raylib
>= "0.5.1" -
rune
>= "1.0.0~alpha1" & < "1.0.0~alpha3" -
server-reason-react
>= "0.3.0" -
sqlgg
>= "20260721" - srt
-
unix-errno
>= "0.6.0" -
xedbindings
>= "0.14" -
zstd
>= "0.3"
Conflicts
None
Build status
Results of building integers with each compiler on check.ci.ocaml.org, run of against opam-repository 7cdc698. All results for this package.
Each result links to its build log. To keep crawlers from overloading the site, build logs require a GitHub sign-in (see ocurrent/opam-health-check). On your first log, GitHub asks you to “Authorize opam-health-check”, the OCurrent app that runs these checks; it sees only your public profile, not your repositories. The sign-in lasts 30 days.
| Version | OCaml 4.11 | OCaml 4.14 | OCaml 5.2 | OCaml 5.4 | OCaml 5.5 |
|---|---|---|---|---|---|
| 0.8.0 (this version) | good | good | good | good | good |
- good Package successfully built
- partial One of the dependencies failed to build
- bad Package failed to build
- n/a Package is not available in this environment
- internal Internal failure