exponent static method
Converts double precision to single precision approximately
Converts mantisa from 53-bits to 20-bits
Implementation
static int exponent(double inp) {
final lst = Float64List.fromList([inp]).buffer.asUint16List();
int ret = 0;
if (Endian.host == Endian.little) {
ret = lst[3] >> 4;
} else {
ret = lst[4] >> 4;
}
return ret - 1023;
}