MCPcopy Create free account
hub / github.com/ThePhD/sol2 / get_error

Function get_error

include/sol/stack.hpp:365–371  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

363
364 namespace stack_detail {
365 inline error get_error(lua_State* L, int target) {
366 auto maybe_exc = stack::check_get<error&>(L, target);
367 if (maybe_exc.has_value()) {
368 return maybe_exc.value();
369 }
370 return error(detail::direct_error, stack::get<std::string>(L, target));
371 }
372
373 inline detail::error_exception get_error_exception(lua_State* L, int target) {
374 auto maybe_exc = stack::check_get<detail::error_exception&>(L, target);

Callers 2

getMethod · 0.85
getMethod · 0.85

Calls 3

errorClass · 0.85
has_valueMethod · 0.45
valueMethod · 0.45

Tested by

no test coverage detected