Function mozjs::jsapi::JS_GetStringEncodingLength
source ยท pub unsafe extern "C" fn JS_GetStringEncodingLength(
cx: *mut JSContext,
str_: *mut JSString,
) -> usize
Expand description
Get number of bytes in the string encoding (without accounting for a terminating zero bytes. The function returns (size_t) -1 if the string can not be encoded into bytes and reports an error using cx accordingly.