MCPcopy Create free account
hub / github.com/GNOME/gjs / call

Method call

gi/function.cpp:1187–1200  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1185}
1186
1187bool Function::call(JSContext* cx, unsigned argc, JS::Value* vp) {
1188 JS::CallArgs args = JS::CallArgsFromVp(argc, vp);
1189 JS::RootedObject callee{cx, &args.callee()};
1190
1191 Function* priv;
1192 if (!Function::for_js_typecheck(cx, callee, &priv, &args))
1193 return false;
1194
1195 gjs_debug_marshal(GJS_DEBUG_GFUNCTION, "Call callee %p priv %p",
1196 callee.get(), priv);
1197
1198 g_assert(priv);
1199 return priv->invoke(cx, args);
1200}
1201
1202Function::~Function() {
1203 gi_function_invoker_clear(&m_invoker);

Callers 15

checkSymbolFunction · 0.80
_legacy.jsFile · 0.80
_initFunction · 0.80
_connectFunction · 0.80
_connectAfterFunction · 0.80
_interfaceInstanceOfFunction · 0.80
_initFunction · 0.80
_initFunction · 0.80
_proxyInvokerFunction · 0.80
_makeProxyMethodFunction · 0.80
_convertToNativeSignalFunction · 0.80

Calls 2

getMethod · 0.45
invokeMethod · 0.45

Tested by

no test coverage detected