For integers larger than MAX_INT, they are stored internally in doubles, but if there is no fractional part they are expected to be displayed in integer format.
The range of integers that can be safely represented by a double variable is [-(2^53-1), 2^53-1].
Number.MAX_SAFE_INTEGERNumber.MIN_SAFE_INTEGER
Numbers with no fractional part in this range are expected to be displayed in integer form.
I have tested with x86_64(linux & Win 10), aarch64(linux), armv7l(linux).
For integers larger than MAX_INT, they are stored internally in doubles, but if there is no fractional part they are expected to be displayed in integer format.
The range of integers that can be safely represented by a double variable is [-(2^53-1), 2^53-1]. Number.MAX_SAFE_INTEGER Number.MIN_SAFE_INTEGER Numbers with no fractional part in this range are expected to be displayed in integer form.
I have tested with x86_64(linux & Win 10), aarch64(linux), armv7l(linux).
Output of sample code before modification
Output of sample code after modification
Sample code
fixes: #758