Module Std_kernel.Int_intf

module Int_intf: Int_intf

module type S = sig .. end

delimiter is underscore by default

The number of bits available in this integer type. Note that the integer representations are signed

Infix operators and constants


Negation

A sub-module designed to be opened to make working with ints more convenient.

Successor and predecessor functions


Returns the absolute value of the argument. May be negative if the input is min_value

Integer remainder, with the semantics of mod in Pervasives or rem in Int32/64, i.e. if y is not zero, the result of rem x y satisfies the following properties: x = (x / y) * y + rem x y and abs (rem x y) <= abs y - 1. If y = 0, rem x y raises Division_by_zero. Notice that rem x y is nonpositive if and only if x < 0.

The largest representable integer

The smallest representable integer

Bit-wise logical operations


Bit-shifting operations

The results are unspecified for negative shifts and shifts >= num_bits

shifts left, filling in with zeroes

shifts right, preserving the sign of the input.

shifts right, filling in with zeroes, which will not preserve the sign of the input

Increment and decrement functions for integer references


Conversion functions to related integer types