Isize
Isize is a primitive signed integer type in the Rust programming language. Its width is determined by the target platform’s pointer size, commonly 32 bits on 32‑bit targets and 64 bits on 64‑bit targets. Consequently, isize uses the same number of bits as a pointer on the target architecture. The range is the standard signed range for that width: isize::MIN to isize::MAX, corresponding to -(2^(N-1)) to 2^(N-1) - 1.
Isize is the signed counterpart to usize, the unsigned pointer-sized integer type. It is typically used for
In practice, isize can be used for arithmetic that may produce negative results, for example when computing
Related types include usize (the unsigned, pointer-sized counterpart) and, in C interop, the similarly named ssize_t