Skip to content

Commit

Permalink
Compatibility with older Pythons
Browse files Browse the repository at this point in the history
  • Loading branch information
pitrou committed Jun 8, 2023
1 parent 2a93aa1 commit 5f0abee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/pyarrow/tests/test_compute.py
Original file line number Diff line number Diff line change
Expand Up @@ -1844,9 +1844,9 @@ def largest_scaled_float_not_above(val, scale):
float_val = float(val) / 10**scale
if float_val * 10**scale > val:
# Take the float just below... it *should* satisfy
float_val = math.nextafter(float_val, 0.0)
float_val = np.nextafter(float_val, 0.0)
if float_val * 10**scale > val:
float_val = math.nextafter(float_val, 0.0)
float_val = np.nextafter(float_val, 0.0)
assert float_val * 10**scale <= val
return float_val

Expand Down

0 comments on commit 5f0abee

Please sign in to comment.