lua: allow the Log api to debug boxed objects (useful for pods)

This commit is contained in:
George Kiagiadakis
2021-06-02 13:13:20 +03:00
parent 132de309cb
commit 9db0e741cd
4 changed files with 32 additions and 5 deletions

View File

@@ -226,6 +226,11 @@ log_log (lua_State *L, GLogLevelFlags lvl)
type = G_TYPE_FROM_INSTANCE (instance);
index++;
}
else if (wplua_isboxed (L, 1, G_TYPE_BOXED)) {
instance = wplua_toboxed (L, 1);
type = wplua_gvalue_userdata_type (L, 1);
index++;
}
message = luaL_checkstring (L, index);
tmp = g_strrstr (ar.source, ".lua");