diff options
Diffstat (limited to 'src/tools.c')
-rw-r--r-- | src/tools.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/src/tools.c b/src/tools.c index 3e3efeb..ddc879e 100644 --- a/src/tools.c +++ b/src/tools.c | |||
@@ -46,7 +46,7 @@ THE SOFTWARE. | |||
46 | #include "lanes.h" | 46 | #include "lanes.h" |
47 | 47 | ||
48 | // functions implemented in deep.c | 48 | // functions implemented in deep.c |
49 | extern luaG_IdFunction copydeep( Universe* U, lua_State* L, lua_State* L2, int index, enum eLookupMode mode_); | 49 | extern luaG_IdFunction copydeep( Universe* U, lua_State* L, lua_State* L2, int index, LookupMode mode_); |
50 | extern void push_registry_subtable( lua_State* L, void* key_); | 50 | extern void push_registry_subtable( lua_State* L, void* key_); |
51 | 51 | ||
52 | char const* const CONFIG_REGKEY = "ee932492-a654-4506-9da8-f16540bdb5d4"; | 52 | char const* const CONFIG_REGKEY = "ee932492-a654-4506-9da8-f16540bdb5d4"; |
@@ -585,7 +585,7 @@ void populate_func_lookup_table( lua_State* L, int _i, char const* name_) | |||
585 | DEBUGSPEW_CODE( -- U->debugspew_indent_depth); | 585 | DEBUGSPEW_CODE( -- U->debugspew_indent_depth); |
586 | } | 586 | } |
587 | 587 | ||
588 | void call_on_state_create( Universe* U, lua_State* L, lua_State* from_, enum eLookupMode mode_) | 588 | void call_on_state_create( Universe* U, lua_State* L, lua_State* from_, LookupMode mode_) |
589 | { | 589 | { |
590 | if( U->on_state_create_func != NULL) | 590 | if( U->on_state_create_func != NULL) |
591 | { | 591 | { |
@@ -828,7 +828,7 @@ static int table_lookup_sentinel( lua_State* L) | |||
828 | /* | 828 | /* |
829 | * retrieve the name of a function/table in the lookup database | 829 | * retrieve the name of a function/table in the lookup database |
830 | */ | 830 | */ |
831 | static char const* find_lookup_name( lua_State* L, uint_t i, enum eLookupMode mode_, char const* upName_, size_t* len_) | 831 | static char const* find_lookup_name( lua_State* L, uint_t i, LookupMode mode_, char const* upName_, size_t* len_) |
832 | { | 832 | { |
833 | DEBUGSPEW_CODE( Universe* const U = universe_get( L)); | 833 | DEBUGSPEW_CODE( Universe* const U = universe_get( L)); |
834 | char const* fqn; | 834 | char const* fqn; |
@@ -899,7 +899,7 @@ static char const* find_lookup_name( lua_State* L, uint_t i, enum eLookupMode mo | |||
899 | /* | 899 | /* |
900 | * Push a looked-up table, or nothing if we found nothing | 900 | * Push a looked-up table, or nothing if we found nothing |
901 | */ | 901 | */ |
902 | static bool_t lookup_table( lua_State* L2, lua_State* L, uint_t i, enum eLookupMode mode_, char const* upName_) | 902 | static bool_t lookup_table( lua_State* L2, lua_State* L, uint_t i, LookupMode mode_, char const* upName_) |
903 | { | 903 | { |
904 | // get the name of the table we want to send | 904 | // get the name of the table we want to send |
905 | size_t len; | 905 | size_t len; |
@@ -1195,7 +1195,7 @@ int luaG_nameof( lua_State* L) | |||
1195 | /* | 1195 | /* |
1196 | * Push a looked-up native/LuaJIT function. | 1196 | * Push a looked-up native/LuaJIT function. |
1197 | */ | 1197 | */ |
1198 | static void lookup_native_func( lua_State* L2, lua_State* L, uint_t i, enum eLookupMode mode_, char const* upName_) | 1198 | static void lookup_native_func( lua_State* L2, lua_State* L, uint_t i, LookupMode mode_, char const* upName_) |
1199 | { | 1199 | { |
1200 | // get the name of the function we want to send | 1200 | // get the name of the function we want to send |
1201 | size_t len; | 1201 | size_t len; |
@@ -1276,9 +1276,9 @@ enum e_vt | |||
1276 | VT_KEY, | 1276 | VT_KEY, |
1277 | VT_METATABLE | 1277 | VT_METATABLE |
1278 | }; | 1278 | }; |
1279 | static bool_t inter_copy_one_( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_State* L, uint_t i, enum e_vt value_type, enum eLookupMode mode_, char const* upName_); | 1279 | static bool_t inter_copy_one_( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_State* L, uint_t i, enum e_vt value_type, LookupMode mode_, char const* upName_); |
1280 | 1280 | ||
1281 | static void inter_copy_func( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_State* L, uint_t i, enum eLookupMode mode_, char const* upName_) | 1281 | static void inter_copy_func( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_State* L, uint_t i, LookupMode mode_, char const* upName_) |
1282 | { | 1282 | { |
1283 | int n, needToPush; | 1283 | int n, needToPush; |
1284 | luaL_Buffer b; | 1284 | luaL_Buffer b; |
@@ -1427,7 +1427,7 @@ static void inter_copy_func( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_ | |||
1427 | * | 1427 | * |
1428 | * Always pushes a function to 'L2'. | 1428 | * Always pushes a function to 'L2'. |
1429 | */ | 1429 | */ |
1430 | static void push_cached_func( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_State* L, uint_t i, enum eLookupMode mode_, char const* upName_) | 1430 | static void push_cached_func( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_State* L, uint_t i, LookupMode mode_, char const* upName_) |
1431 | { | 1431 | { |
1432 | FuncSubType funcSubType; | 1432 | FuncSubType funcSubType; |
1433 | /*lua_CFunction cfunc =*/ luaG_tocfunction( L, i, &funcSubType); // NULL for LuaJIT-fast && bytecode functions | 1433 | /*lua_CFunction cfunc =*/ luaG_tocfunction( L, i, &funcSubType); // NULL for LuaJIT-fast && bytecode functions |
@@ -1480,7 +1480,7 @@ static void push_cached_func( Universe* U, lua_State* L2, uint_t L2_cache_i, lua | |||
1480 | } | 1480 | } |
1481 | } | 1481 | } |
1482 | 1482 | ||
1483 | static void inter_copy_keyvaluepair( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_State* L, enum e_vt vt, enum eLookupMode mode_, char const* upName_) | 1483 | static void inter_copy_keyvaluepair( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_State* L, enum e_vt vt, LookupMode mode_, char const* upName_) |
1484 | { | 1484 | { |
1485 | uint_t val_i = lua_gettop( L); | 1485 | uint_t val_i = lua_gettop( L); |
1486 | uint_t key_i = val_i - 1; | 1486 | uint_t key_i = val_i - 1; |
@@ -1542,7 +1542,7 @@ static void inter_copy_keyvaluepair( Universe* U, lua_State* L2, uint_t L2_cache | |||
1542 | * | 1542 | * |
1543 | * Returns TRUE if value was pushed, FALSE if its type is non-supported. | 1543 | * Returns TRUE if value was pushed, FALSE if its type is non-supported. |
1544 | */ | 1544 | */ |
1545 | static bool_t inter_copy_one_( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_State* L, uint_t i, enum e_vt vt, enum eLookupMode mode_, char const* upName_) | 1545 | static bool_t inter_copy_one_( Universe* U, lua_State* L2, uint_t L2_cache_i, lua_State* L, uint_t i, enum e_vt vt, LookupMode mode_, char const* upName_) |
1546 | { | 1546 | { |
1547 | bool_t ret = TRUE; | 1547 | bool_t ret = TRUE; |
1548 | bool_t ignore = FALSE; | 1548 | bool_t ignore = FALSE; |
@@ -1809,7 +1809,7 @@ static bool_t inter_copy_one_( Universe* U, lua_State* L2, uint_t L2_cache_i, lu | |||
1809 | * | 1809 | * |
1810 | * Note: Parameters are in this order ('L' = from first) to be same as 'lua_xmove'. | 1810 | * Note: Parameters are in this order ('L' = from first) to be same as 'lua_xmove'. |
1811 | */ | 1811 | */ |
1812 | int luaG_inter_copy( Universe* U, lua_State* L, lua_State* L2, uint_t n, enum eLookupMode mode_) | 1812 | int luaG_inter_copy( Universe* U, lua_State* L, lua_State* L2, uint_t n, LookupMode mode_) |
1813 | { | 1813 | { |
1814 | uint_t top_L = lua_gettop( L); | 1814 | uint_t top_L = lua_gettop( L); |
1815 | uint_t top_L2 = lua_gettop( L2); | 1815 | uint_t top_L2 = lua_gettop( L2); |
@@ -1867,14 +1867,14 @@ int luaG_inter_copy( Universe* U, lua_State* L, lua_State* L2, uint_t n, enum eL | |||
1867 | } | 1867 | } |
1868 | 1868 | ||
1869 | 1869 | ||
1870 | int luaG_inter_move( Universe* U, lua_State* L, lua_State* L2, uint_t n, enum eLookupMode mode_) | 1870 | int luaG_inter_move( Universe* U, lua_State* L, lua_State* L2, uint_t n, LookupMode mode_) |
1871 | { | 1871 | { |
1872 | int ret = luaG_inter_copy( U, L, L2, n, mode_); | 1872 | int ret = luaG_inter_copy( U, L, L2, n, mode_); |
1873 | lua_pop( L, (int) n); | 1873 | lua_pop( L, (int) n); |
1874 | return ret; | 1874 | return ret; |
1875 | } | 1875 | } |
1876 | 1876 | ||
1877 | int luaG_inter_copy_package( Universe* U, lua_State* L, lua_State* L2, int package_idx_, enum eLookupMode mode_) | 1877 | int luaG_inter_copy_package( Universe* U, lua_State* L, lua_State* L2, int package_idx_, LookupMode mode_) |
1878 | { | 1878 | { |
1879 | DEBUGSPEW_CODE( fprintf( stderr, INDENT_BEGIN "luaG_inter_copy_package()\n" INDENT_END)); | 1879 | DEBUGSPEW_CODE( fprintf( stderr, INDENT_BEGIN "luaG_inter_copy_package()\n" INDENT_END)); |
1880 | DEBUGSPEW_CODE( ++ U->debugspew_indent_depth); | 1880 | DEBUGSPEW_CODE( ++ U->debugspew_indent_depth); |