mirror of
https://github.com/RustPython/RustPython.git
synced 2026-10-28 18:59:04 +08:00
* Fix ldexp to prevent math range errors Implemented IEEE 754-compliant handling for large numbers to avoid overflow and represent results using scientific notation. Fixes #5471 Signed-off-by: Yash Suthar <yashsuthar983@gmail.com> * Fix ldexp to handle denormalized inputs correctly Detect denormalized input values below f64::MIN_POSITIVE Scale subnormal inputs by 2^54 to bring them into normalized range Signed-off-by: Yash Suthar <yashsuthar983@gmail.com> * tests(math): remove expectedFailure from testLdexp_denormal As now we have implemented IEEE 754 format , so this will pass. Signed-off-by: Yash Suthar <yashsuthar983@gmail.com> * Update Lib/test/test_math.py Co-authored-by: Jeong, YunWon <69878+youknowone@users.noreply.github.com> * fixed formate in math.rs Signed-off-by: Yash Suthar <yashsuthar983@gmail.com> --------- Signed-off-by: Yash Suthar <yashsuthar983@gmail.com> Co-authored-by: Jeong, YunWon <69878+youknowone@users.noreply.github.com>