code: def _winpath2bytes_py3(text, codec):
      
  
      # merge surrogate codepoints
      if _normalize_codec(codec).startswith("utf-16"):
          # fast path, utf-16 merges anyway
          return text.encode(codec, _surrogatepass)
      return _decode_surrogatepass(
          text.encode("utf-16-le", _surrogatepass),
          "utf-16-le").encode(codec, _surrogatepass)
docs: Fallback implementation for text including surrogates