rename transcode() as encode_char().