MCPcopy Create free account
hub / github.com/ObEngine/ObEngine / set_default_exception_handler

Function set_default_exception_handler

extlibs/sol3/include/sol/sol.hpp:7584–7590  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7582 } // namespace detail
7583
7584 inline void set_default_exception_handler(lua_State* L, exception_handler_function exf = &detail::default_exception_handler) {
7585 static_assert(sizeof(void*) >= sizeof(exception_handler_function), "void* storage is too small to transport the exception handler: please file a bug on the issue tracker");
7586 void* storage;
7587 std::memcpy(&storage, &exf, sizeof(exception_handler_function));
7588 lua_pushlightuserdata(L, storage);
7589 lua_setglobal(L, detail::default_exception_handler_name());
7590 }
7591} // sol
7592
7593// end of sol/trampoline.hpp

Callers 2

set_default_stateFunction · 0.85
set_exception_handlerMethod · 0.85

Calls 2

lua_pushlightuserdataFunction · 0.85
lua_setglobalFunction · 0.85

Tested by

no test coverage detected