mulChecked method
- I16 other
Multiplies this by another I16, throwing a StateError on overflow or underflow.
Implementation
I16 mulChecked(I16 other) {
var result = value * other.value;
if (result > 32767 || result < -32768) {
throw StateError('I16 multiplication overflow');
}
return I16(result);
}