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

Method trunc

Lib/test/test_os.py:656–656  ·  view source on GitHub ↗
(x)

Source from the content-addressed store, hash-verified

654 attr = name.lower()
655 if name.endswith("TIME"):
656 def trunc(x): return int(x)
657 else:
658 def trunc(x): return x
659 self.assertEqual(trunc(getattr(result, attr)),

Callers 15

testConversionsMethod · 0.80
test_truncMethod · 0.80
test_truncMethod · 0.80
builtin_float.pyFile · 0.80
stdlib_math.pyFile · 0.80
builtin_int.pyFile · 0.80
sec_to_timevalFunction · 0.80
format_complex_floatMethod · 0.80
round_float_digitsFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected