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

Method invert

Lib/test/datetimetester.py:6432–6441  ·  view source on GitHub ↗
(ut, ti)

Source from the content-addressed store, hash-verified

6430
6431 @staticmethod
6432 def invert(ut, ti):
6433 lt = (array('q', ut), array('q', ut))
6434 if ut:
6435 offset = ti[0][0] // SEC
6436 lt[0][0] += offset
6437 lt[1][0] += offset
6438 for i in range(1, len(ut)):
6439 lt[0][i] += ti[i-1][0] // SEC
6440 lt[1][i] += ti[i][0] // SEC
6441 return lt
6442
6443 @classmethod
6444 def fromfile(cls, fileobj):

Callers 1

__init__Method · 0.95

Calls 2

arrayClass · 0.85
lenFunction · 0.85

Tested by

no test coverage detected