MCPcopy Create free account
hub / github.com/RomanKubiak/ctrlr / get_function_object

Function get_function_object

Source/Misc/luabind/src/function_introspection.cpp:58–68  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

56
57namespace {
58 detail::function_object* get_function_object(argument const& fn) {
59 lua_State * L = fn.interpreter();
60 {
61 fn.push(L);
62 detail::stack_pop pop(L, 1);
63 if (!detail::is_luabind_function(L, -1)) {
64 return NULL;
65 }
66 }
67 return *touserdata<detail::function_object*>(getupvalue(fn, 1));
68 }
69
70 std::string get_function_name(argument const& fn) {
71 detail::function_object * f = get_function_object(fn);

Callers 2

get_function_nameFunction · 0.85
get_function_overloadsFunction · 0.85

Calls 4

is_luabind_functionFunction · 0.85
getupvalueFunction · 0.85
interpreterMethod · 0.45
pushMethod · 0.45

Tested by

no test coverage detected