Home
last modified time | relevance | path

Searched refs:__floor__ (Results 1 – 14 of 14) sorted by relevance

/third_party/python/Lib/test/
Dtest_float.py319 self.assertIsInstance(float(0.5).__floor__(), int)
320 self.assertEqual(float(0.5).__floor__(), 0)
321 self.assertEqual(float(1.0).__floor__(), 1)
322 self.assertEqual(float(1.5).__floor__(), 1)
323 self.assertEqual(float(-0.5).__floor__(), -1)
324 self.assertEqual(float(-1.0).__floor__(), -1)
325 self.assertEqual(float(-1.5).__floor__(), -2)
326 self.assertEqual(float(1.23e167).__floor__(), 1.23e167)
327 self.assertEqual(float(-1.23e167).__floor__(), -1.23e167)
328 self.assertRaises(ValueError, float("nan").__floor__)
[all …]
Dtest_math.py535 def __floor__(self): member in MathTests.testFloor.TestFloor
538 def __floor__(self): member in MathTests.testFloor.FloatFloor
548 t.__floor__ = lambda *args: args
/third_party/python/Lib/
Dnumbers.py179 def __floor__(self): member in Real
Dfractions.py603 def __floor__(a): member in Fraction
D_pydecimal.py1892 def __floor__(self): member in Decimal
/third_party/python/Lib/unittest/test/testmock/
Dtestmagicmethods.py286 self.assertEqual(math.floor(mock), mock.__floor__())
312 self.assertEqual(math.floor(mock), mock.__floor__())
/third_party/python/Doc/library/
Dfractions.rst153 .. method:: __floor__()
Dmath.rst81 If *x* is not a float, delegates to ``x.__floor__()``, which should return an
Dunittest.mock.rst2014 * ``__round__``, ``__floor__``, ``__trunc__`` and ``__ceil__``
/third_party/protobuf/python/google/protobuf/internal/
Dtest_util.py856 def __floor__(self): member in NonStandardInteger
/third_party/python/Misc/NEWS.d/
D3.9.0a2.rst197 Added ``__floor__`` and ``__ceil__`` methods to float object. Patch by
/third_party/python/Modules/
Dmathmodule.c1270 _Py_IDENTIFIER(__floor__); in math_floor()
/third_party/python/Doc/reference/
Ddatamodel.rst2681 object.__floor__(self)
/third_party/python/Misc/
DHISTORY14203 - In the math module, correctly lookup __trunc__, __ceil__, and __floor__ as
16781 __floor__ and __trunc__, to give support for round, math.ceil,