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

Function utf_16_ex_decode

Lib/_pycodecs.py:245–260  ·  view source on GitHub ↗

None

(data, errors="strict", byteorder=0, final=0)

Source from the content-addressed store, hash-verified

243
244
245def utf_16_ex_decode(data, errors="strict", byteorder=0, final=0):
246 """None"""
247 if byteorder == 0:
248 bm = "native"
249 elif byteorder == -1:
250 bm = "little"
251 else:
252 bm = "big"
253 consumed = len(data)
254 if final:
255 consumed = 0
256 res, consumed, byteorder = PyUnicode_DecodeUTF16Stateful(
257 data, len(data), errors, bm, final
258 )
259 res = "".join(res)
260 return res, consumed, byteorder
261
262
263def utf_32_ex_decode(data, errors="strict", byteorder=0, final=0):

Callers

nothing calls this directly

Calls 3

lenFunction · 0.85
joinMethod · 0.45

Tested by

no test coverage detected