summaryrefslogtreecommitdiff
path: root/py/objfloat.c
diff options
context:
space:
mode:
authorYoctopuce dev <dev@yoctopuce.com>2025-07-04 22:32:00 +0200
committerDamien George <damien@micropython.org>2025-08-01 00:47:33 +1000
commite4e1c9f4132f839dac0291557d9b992f67577fd3 (patch)
tree2a8b07a6cdbb40ac6e9e4fa81ecdf4dbe8c0ba83 /py/objfloat.c
parentffa98cb0143c43af9f4c61142784a08a19f660c5 (diff)
py/parsenum: Refactor float parsing code.
This commit extracts from the current float parsing code two functions which could be reused elsewhere in MicroPython. The code used to multiply a float x by a power of 10 is also simplified by applying the binary exponent separately from the power of 5. This avoids the risk of overflow in the intermediate stage, before multiplying by x. Signed-off-by: Yoctopuce dev <dev@yoctopuce.com>
Diffstat (limited to 'py/objfloat.c')
0 files changed, 0 insertions, 0 deletions