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

Method nreadahead

tools/python-3.11.9-amd64/Lib/_pyio.py:552–559  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

550 # For backwards compatibility, a (slowish) readline().
551 if hasattr(self, "peek"):
552 def nreadahead():
553 readahead = self.peek(1)
554 if not readahead:
555 return 1
556 n = (readahead.find(b"\n") + 1) or len(readahead)
557 if size >= 0:
558 n = min(n, size)
559 return n
560 else:
561 def nreadahead():
562 return 1

Callers

nothing calls this directly

Calls 3

minFunction · 0.85
peekMethod · 0.45
findMethod · 0.45

Tested by

no test coverage detected