pub type JSResolveOp = Option<unsafe extern "C" fn(cx: *mut JSContext, obj: HandleObject, id: HandleId, resolvedp: *mut bool) -> bool>;
Expand description
Resolve a lazy property named by id in obj by defining it directly in obj. Lazy properties are those reflected from some peer native property space (e.g., the DOM attributes for a given node reflected as obj) on demand.
JS looks for a property in an object, and if not found, tries to resolve the given id. *resolvedp should be set to true iff the property was defined on |obj|.
See JS::dbg::ShouldAvoidSideEffects in Debug.h if this function has any other side-effect than just resolving the property.
Aliased Type§
pub enum JSResolveOp {
None,
Some(unsafe extern "C" fn(*mut JSContext, Handle<*mut JSObject>, Handle<PropertyKey>, *mut bool) -> bool),
}