If you look for performances, you should always prefer append_in which allow you to recycle
a unique common buffer (each call of to_string allocate a new object!).
If you look for performances, you should always prefer append_in_unicode which allow you to recycle
a unique common buffer (each call of to_unicode_string allocate a new object!).
If you look for performances, you should always prefer append_in_format which allow you to recycle
a unique common buffer (each call of to_string_format allocate a new object!).
If you look for performances, you should always prefer append_in_unicode_format which allow you to recycle
a unique common buffer (each call of to_unicode_string_format allocate a new object!).
If you look for performances, you should always prefer to_octal_in which allow you to recycle
a unique common buffer (each call of to_octal allocate a new object!).
If you look for performances, you should always prefer to_hexadecimal_in which allow you to recycle
a unique common buffer (each call of to_hexadecimal allocate a new object!).
According to the ANSI C99: if Current and other are both non-negative, the Result is the
quotient of the Euclidian division; but this is not the general case, the Result value is the
algebraic quotient Current/other with any fractional part discarded. (This is often called
"truncated toward zero"). So, the corresponding remainder value only verifies the expression
remainder.abs < other.abs.
See also infix "//", infix "#\\".
require
other /= zero
ensure
Result * other + Current #\\ other = Current
ansi_c_remainder: other |<< 1 /= zero implies Current - Result * other.abs < other.abs
ansi_c_good_case: Current >= zero and other > zero implies Current - Result * other >= zero
Remainder of the integer division of Current by other.
According to the ANSI C99:
* if Current and other are both non-negative,
the Result is the remainder of the Euclidian division.
* but this is not the general case,
Result as the same sign as Current and only verify
the expression Result.abs < other.abs.
See also infix "\\", infix "#//".
require
other /= zero
ensure
Current - Result #\\ other = zero
ansi_c_remainder: other |<< 1 /= zero implies Result.abs < other.abs
ansi_c_good_case: Current >= zero and other > zero implies Result >= zero
A value that is equal to Current if it is between the limits set by
a_min and a_max.
Otherwise it's a_min if Current is smaller or a_max if Current
is greater
It's a shortcut for Current.min(a_max).max(a_min) also known as
"clamp" in the widespread C library Glib