aboutsummaryrefslogtreecommitdiff
path: root/src/lanes.cpp
diff options
context:
space:
mode:
authorBenoit Germain <benoit.germain@ubisoft.com>2025-03-14 11:32:58 +0100
committerBenoit Germain <benoit.germain@ubisoft.com>2025-03-14 11:32:58 +0100
commitdee0756ff21c1f7dd4eea067dfb90feb1ba4763d (patch)
tree981ddd4ddc22bc1fae54ce3e0034da746571fb1a /src/lanes.cpp
parent536a64557c82c350fd73ea64c6d4dd1737896579 (diff)
downloadlanes-dee0756ff21c1f7dd4eea067dfb90feb1ba4763d.tar.gz
lanes-dee0756ff21c1f7dd4eea067dfb90feb1ba4763d.tar.bz2
lanes-dee0756ff21c1f7dd4eea067dfb90feb1ba4763d.zip
lanes/core.[so|dll] → lanes_core.[so|dll]
Diffstat (limited to 'src/lanes.cpp')
-rw-r--r--src/lanes.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/lanes.cpp b/src/lanes.cpp
index 678540d..15e04a3 100644
--- a/src/lanes.cpp
+++ b/src/lanes.cpp
@@ -760,7 +760,7 @@ LUAG_FUNC(configure)
760 760
761 // register all native functions found in that module in the transferable functions database 761 // register all native functions found in that module in the transferable functions database
762 // we process it before _G because we don't want to find the module when scanning _G (this would generate longer names) 762 // we process it before _G because we don't want to find the module when scanning _G (this would generate longer names)
763 // for example in package.loaded["lanes.core"].* 763 // for example in package.loaded["lanes_core"].*
764 tools::PopulateFuncLookupTable(L_, kIdxTop, _name); 764 tools::PopulateFuncLookupTable(L_, kIdxTop, _name);
765 STACK_CHECK(L_, 2); 765 STACK_CHECK(L_, 2);
766 766
@@ -862,11 +862,11 @@ LANES_API int luaopen_lanes_core(lua_State* const L_)
862 // Create main module interface table 862 // Create main module interface table
863 // we only have 1 closure, which must be called to configure Lanes 863 // we only have 1 closure, which must be called to configure Lanes
864 lua_newtable(L_); // L_: M 864 lua_newtable(L_); // L_: M
865 lua_pushvalue(L_, 1); // L_: M "lanes.core" 865 lua_pushvalue(L_, 1); // L_: M "lanes_core"
866 lua_pushvalue(L_, -2); // L_: M "lanes.core" M 866 lua_pushvalue(L_, -2); // L_: M "lanes_core" M
867 lua_pushcclosure(L_, LG_configure, 2); // L_: M LG_configure() 867 lua_pushcclosure(L_, LG_configure, 2); // L_: M LG_configure()
868 kConfigRegKey.pushValue(L_); // L_: M LG_configure() settings 868 kConfigRegKey.pushValue(L_); // L_: M LG_configure() settings
869 if (!lua_isnil(L_, -1)) { // this is not the first require "lanes.core": call configure() immediately 869 if (!lua_isnil(L_, -1)) { // this is not the first require "lanes_core": call configure() immediately
870 lua_pushvalue(L_, -1); // L_: M LG_configure() settings settings 870 lua_pushvalue(L_, -1); // L_: M LG_configure() settings settings
871 lua_setfield(L_, -4, "settings"); // L_: M LG_configure() settings 871 lua_setfield(L_, -4, "settings"); // L_: M LG_configure() settings
872 lua_call(L_, 1, 0); // L_: M 872 lua_call(L_, 1, 0); // L_: M
@@ -898,8 +898,8 @@ static int default_luaopen_lanes(lua_State* const L_)
898LANES_API void luaopen_lanes_embedded(lua_State* const L_, lua_CFunction const luaopen_lanes_) 898LANES_API void luaopen_lanes_embedded(lua_State* const L_, lua_CFunction const luaopen_lanes_)
899{ 899{
900 STACK_CHECK_START_REL(L_, 0); 900 STACK_CHECK_START_REL(L_, 0);
901 // pre-require lanes.core so that when lanes.lua calls require "lanes.core" it finds it is already loaded 901 // pre-require lanes_core so that when lanes.lua calls require "lanes_core" it finds it is already loaded
902 luaL_requiref(L_, kLanesCoreLibName, luaopen_lanes_core, 0); // L_: ... lanes.core 902 luaL_requiref(L_, kLanesCoreLibName, luaopen_lanes_core, 0); // L_: ... lanes_core
903 lua_pop(L_, 1); // L_: ... 903 lua_pop(L_, 1); // L_: ...
904 STACK_CHECK(L_, 0); 904 STACK_CHECK(L_, 0);
905 // call user-provided function that runs the chunk "lanes.lua" from wherever they stored it 905 // call user-provided function that runs the chunk "lanes.lua" from wherever they stored it