UTF-32 encoding with BOM.
(obj, errors="strict")
| 515 | |
| 516 | |
| 517 | def 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 | |
| 523 | def utf_32_le_encode(obj, errors="strict"): |
nothing calls this directly
no test coverage detected