Function mozjs_sys::jsapi::JS::EncodeNarrowToUtf8

source ยท
pub unsafe extern "C" fn EncodeNarrowToUtf8(
    cx: *mut JSContext,
    chars: *const c_char,
) -> UniqueChars
Expand description

Encode a narrow multibyte character string to a UTF-8 string.

NOTE: Should only be used when interacting with POSIX/OS functions and not for encoding ASCII/Latin-1/etc. strings to UTF-8.