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

Method _check_newline

tools/python-3.11.9-amd64/Lib/_pyio.py:2053–2057  ·  view source on GitHub ↗
(self, newline)

Source from the content-addressed store, hash-verified

2051 line_buffering, write_through)
2052
2053 def _check_newline(self, newline):
2054 if newline is not None and not isinstance(newline, str):
2055 raise TypeError("illegal newline type: %r" % (type(newline),))
2056 if newline not in (None, "", "\n", "\r", "\r\n"):
2057 raise ValueError("illegal newline value: %r" % (newline,))
2058
2059 def _configure(self, encoding=None, errors=None, newline=None,
2060 line_buffering=False, write_through=False):

Callers 2

__init__Method · 0.95
reconfigureMethod · 0.95

Calls 1

typeClass · 0.50

Tested by

no test coverage detected