MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / truncate

Method truncate

tools/python-3.11.9-amd64/Lib/_pyio.py:1291–1296  ·  view source on GitHub ↗
(self, pos=None)

Source from the content-addressed store, hash-verified

1289 return written
1290
1291 def truncate(self, pos=None):
1292 with self._write_lock:
1293 self._flush_unlocked()
1294 if pos is None:
1295 pos = self.raw.tell()
1296 return self.raw.truncate(pos)
1297
1298 def flush(self):
1299 with self._write_lock:

Callers

nothing calls this directly

Calls 3

_flush_unlockedMethod · 0.95
tellMethod · 0.45
truncateMethod · 0.45

Tested by

no test coverage detected