Function mozjs::jsapi::JS_GetFunctionId

source ·
pub unsafe extern "C" fn JS_GetFunctionId(
    fun: *mut JSFunction
) -> *mut JSString
Expand description

Return the function’s identifier as a JSString, or null if fun is unnamed. The returned string lives as long as fun, so you don’t need to root a saved reference to it if fun is well-connected or rooted, and provided you bound the use of the saved reference by fun’s lifetime.