PyUnicode_TranslateCharmap

Translate a Py_UNICODE buffer of the given length by applying a character mapping table to it and return the resulting Unicode object.

The mapping table must map Unicode ordinal integers to Unicode ordinal integers or None (causing deletion of the character).

Mapping tables may be dictionaries or sequences. Unmapped character ordinals (ones which cause a LookupError) are left untouched and are copied as-is.

  1. PyObject* PyUnicode_TranslateCharmap(Py_UNICODE* data, Py_ssize_t length, PyObject* table, const(char)* errors)
    version(Python_3_3_Or_Later)
    extern (C)
    PyUnicode_TranslateCharmap
  2. alias PyUnicode_TranslateCharmap = PyUnicodeUCS2_TranslateCharmap
  3. alias PyUnicode_TranslateCharmap = PyUnicodeUCS4_TranslateCharmap

Meta