aboutsummaryrefslogtreecommitdiff
path: root/src/lanes.lua
diff options
context:
space:
mode:
authorBenoit Germain <benoit.germain@ubisoft.com>2024-12-03 10:26:47 +0100
committerBenoit Germain <benoit.germain@ubisoft.com>2024-12-03 10:26:47 +0100
commit307fd830eb168005a3ba3d557343284814757eff (patch)
treeeb14512492d58e33585bc5df3f3d9b23d7308934 /src/lanes.lua
parentca7657e24549acb8a2dd45fa81c309b5bf9f61ee (diff)
downloadlanes-307fd830eb168005a3ba3d557343284814757eff.tar.gz
lanes-307fd830eb168005a3ba3d557343284814757eff.tar.bz2
lanes-307fd830eb168005a3ba3d557343284814757eff.zip
New method linda:restrict()
Diffstat (limited to 'src/lanes.lua')
-rw-r--r--src/lanes.lua1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lanes.lua b/src/lanes.lua
index dfa959d..8d8f25d 100644
--- a/src/lanes.lua
+++ b/src/lanes.lua
@@ -448,6 +448,7 @@ local configure_timers = function()
448 448
449 -- Timer lane; initialize only on the first 'require "lanes"' instance (which naturally has 'table' always declared) 449 -- Timer lane; initialize only on the first 'require "lanes"' instance (which naturally has 'table' always declared)
450 local first_time_key = "first time" 450 local first_time_key = "first time"
451 timerLinda:restrict(first_time_key, "set/get")
451 local _, _first_time_val = timerLinda:get(first_time_key) 452 local _, _first_time_val = timerLinda:get(first_time_key)
452 local first_time = (_first_time_val == nil) 453 local first_time = (_first_time_val == nil)
453 timerLinda:set(first_time_key, true) 454 timerLinda:set(first_time_key, true)