Return a float representation (possibly approximate) of `int_val**-scale`
(int_val, scale)
| 2335 | |
| 2336 | |
| 2337 | def scaled_float(int_val, scale): |
| 2338 | """ |
| 2339 | Return a float representation (possibly approximate) of `int_val**-scale` |
| 2340 | """ |
| 2341 | assert isinstance(int_val, int) |
| 2342 | unscaled = decimal.Decimal(int_val) |
| 2343 | scaled = unscaled.scaleb(-scale) |
| 2344 | float_val = float(scaled) |
| 2345 | return float_val |
| 2346 | |
| 2347 | |
| 2348 | def integral_float_to_decimal_cast_cases(float_ty, max_precision): |
no test coverage detected