// ToInt16Checked attempts to cast the Int32 to a Int16.
// The second return value will be false if there was an overflow or any other loss of precision.
// For example, going from Float64 to Int64 will result in anything after the decimal being truncated.
ToInt16Checked attempts to cast the Int32 to a Int16.
The second return value will be false if there was an overflow or any other loss of precision.
For example, going from Float64 to Int64 will result in anything after the decimal being truncated.
// ToInt16Checked attempts to cast the Int32 to a Int16 . // The second return value will be false if there was an overflow or any other loss of precision . // For example going from Float64 to Int64 will result in anything after the decimal being truncated .
func (t Int32) ToInt16Checked() (Int16, Boolean) {
	var converted Int16
	converted = Int16(t)
	v, err := converted.ToInt32().Eq(t)
	return converted, Boolean(err == nil && v)
}
func ( t Int32 ) ToInt16Checked ( ) ( Int16 , Boolean ) { var converted Int16 converted = Int16 ( t ) v , err := converted . ToInt32 ( ) . Eq ( t ) return converted , Boolean ( err == nil && v ) }
ToInt16Checked attempts to cast the Int32 to a Int16.
ToInt16Checked attempts to cast the Int32 to a Int16 .