Function
codecs.make_encoding_map

Signature

make_encoding_map(decoding_map)

Documentation String

Creates an encoding map from a decoding map.

If a target mapping in the decoding map occurs multiple times, then that target is mapped to None (undefined mapping), causing an exception when encountered by the charmap codec during translation.

One example where this happens is cp875.py which decodes multiple character to \u001a.