saturating_mul()

The saturating_mul function multiples two numbers, saturating at -2147483648 and 2147483647 instead of overflowing.

For more information about saturating math functions, see the saturating math docs.

Required arguments

NameTypeDescription
xINTAn integer to multiply with y
yINTAn integer to multiply with x

Returns

ColumnTypeDescription
saturating_mulINTThe result of x*y, saturating at the numeric bounds instead of overflowing

Found an issue on this page?

Report an issue!

Related Content