Skip to main content

publish

Function publish 

Source
pub fn publish(interp: *mut Interp<'static>, context: &JsContext) -> InterpGuard
Expand description

Publish interp (and context) for as long as the guard lives.

The native module loader uses this: it has the running interpreter as a &mut and needs the C API to see it. Everything the module does — JS_NewClass, JS_ToInt32, JS_NewObject — then runs against that interpreter rather than a second one.