MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_fma_single_round

Method test_fma_single_round

Lib/test/test_math.py:2872–2874  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

2870 self.assertEqual(math.fma(a, b, -c), c)
2871
2872 def test_fma_single_round(self):
2873 a = float.fromhex('0x1p-50')
2874 self.assertEqual(math.fma(a - 1.0, a + 1.0, 1.0), a*a)
2875
2876 def test_random(self):
2877 # A collection of randomly generated inputs for which the naive FMA

Callers

nothing calls this directly

Calls 3

fromhexMethod · 0.45
assertEqualMethod · 0.45
fmaMethod · 0.45

Tested by

no test coverage detected