Lines Matching refs:from_float
27 return op(F.from_float(self.value), other)
249 self.assertRaises(TypeError, F.from_float, 3+4j)
250 self.assertEqual((10, 1), _components(F.from_float(10)))
252 self.assertEqual((bigint, 1), _components(F.from_float(bigint)))
253 self.assertEqual((0, 1), _components(F.from_float(-0.0)))
254 self.assertEqual((10, 1), _components(F.from_float(10.0)))
255 self.assertEqual((-5, 2), _components(F.from_float(-2.5)))
257 _components(F.from_float(1e23)))
258 self.assertEqual(float(10**23), float(F.from_float(1e23)))
260 _components(F.from_float(3.2)))
261 self.assertEqual(3.2, float(F.from_float(3.2)))
268 F.from_float, inf)
271 F.from_float, -inf)
274 F.from_float, nan)