Khem Raj 9bfe6f0ea9 python3-fastnumbers: fix denoise of large floats when built with clang
float_as_int_without_noise() returns early when the floored value fits
in a long, checking it with floor_val == static_cast<long>(floor_val).
For values outside the range of long the conversion is undefined
behavior; clang -O2 folds the round trip into "floor_val is integral",
which is always true, so the denoising is skipped:

  FAIL: tests/test_fastnumbers_examples.py:test_try_real
  FAIL: tests/test_fastnumbers_examples.py:test_try_forceint
  assert 3452999999999999737856 == 3453000000000000000000

Add a patch that only does the conversion when the value is in range.
A reduced reproducer returns the wrong answer with the recipe's clang++
at -O2 and the right one with the fix (and with -O0 or gcc).

AI-Generated: Uses Claude Code
Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
2026-09-12 16:52:16 -07:00
2026-06-23 00:45:59 -07:00

Collection of layers for the OE-core universe

Main layer maintainer: Khem Raj raj.khem@gmail.com

This repository is a collection of layers to supplement OE-Core with additional packages, Each layer have designated maintainer Please see the respective READMEs in the layer subdirectories

S
Description
No description provided
Readme
127 MiB
Languages
BitBake 86.5%
Shell 5.8%
C 2.7%
Roff 1.9%
NASL 1.7%
Other 1.2%