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

Function utf_32_encode

Lib/_pycodecs.py:517–520  ·  view source on GitHub ↗

UTF-32 encoding with BOM.

(obj, errors="strict")

Source from the content-addressed store, hash-verified

515
516
517def utf_32_encode(obj, errors="strict"):
518 """UTF-32 encoding with BOM."""
519 encoded = PyUnicode_EncodeUTF32(obj, len(obj), errors, "native")
520 return bytes(encoded), len(obj)
521
522
523def utf_32_le_encode(obj, errors="strict"):

Callers

nothing calls this directly

Calls 2

PyUnicode_EncodeUTF32Function · 0.85
lenFunction · 0.85

Tested by

no test coverage detected