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

Function sol_lua_push

examples/source/customization_base_object_catch.cpp:137–140  ·  view source on GitHub ↗

Defining a customization point that lets us put the correct object type on the stack.

Source from the content-addressed store, hash-verified

135// Defining a customization point that lets us put the correct
136// object type on the stack.
137int sol_lua_push(sol::types<BaseObject>, lua_State* L,
138 const BaseObject& obj) {
139 return obj.pushAsRetyped(L, BaseObjectLifetime::Value);
140}
141int sol_lua_push(sol::types<BaseObject*>, lua_State* L,
142 const BaseObject* obj) {
143 return obj->pushAsRetyped(L, BaseObjectLifetime::Pointer);

Callers

nothing calls this directly

Calls 1

pushAsRetypedMethod · 0.80

Tested by

no test coverage detected