Skip to main content
Contains methods for safely casting between types

Functions

toUint160

Cast a uint256 to a uint160, revert on overflow

Parameters:

Return Values:

toInt128

Cast a int256 to a int128, revert on overflow or underflow

Parameters:

Return Values:

toInt256

Cast a uint256 to a int256, revert on overflow

Parameters:

Return Values: