aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvalid-ptr <konstantin.matveyev@eligovision.ru>2018-11-27 11:24:57 +0300
committerKonstantin S. Matveyev <root@zorro.ev>2018-11-27 11:26:57 +0300
commitb9375bf2b9f59250dc46187b705c9abd90c5d3bc (patch)
treee5fbccd39fd498738ef0db1c981addfcd73f3575
parentabcb7d7aad594cca0049ae7b2a2fe2a61432e0cd (diff)
downloadlanes-b9375bf2b9f59250dc46187b705c9abd90c5d3bc.tar.gz
lanes-b9375bf2b9f59250dc46187b705c9abd90c5d3bc.tar.bz2
lanes-b9375bf2b9f59250dc46187b705c9abd90c5d3bc.zip
Trailing whitespaces deleted from lanes.lua
-rw-r--r--src/lanes.lua20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/lanes.lua b/src/lanes.lua
index 7f2560b..ba9da81 100644
--- a/src/lanes.lua
+++ b/src/lanes.lua
@@ -55,7 +55,7 @@ lanes.configure = function( settings_)
55 end 55 end
56 -- Configure called so remove metatable from lanes 56 -- Configure called so remove metatable from lanes
57 setmetatable( lanes, nil) 57 setmetatable( lanes, nil)
58 -- 58 --
59 -- Cache globals for code that might run under sandboxing 59 -- Cache globals for code that might run under sandboxing
60 -- 60 --
61 local assert = assert( assert) 61 local assert = assert( assert)
@@ -372,7 +372,7 @@ lanes.configure = function( settings_)
372 -- timer tables and sleep in between the timer events. All interaction with 372 -- timer tables and sleep in between the timer events. All interaction with
373 -- the timer lane happens via a 'timer_gateway' Linda, which is common to 373 -- the timer lane happens via a 'timer_gateway' Linda, which is common to
374 -- all that 'require "lanes"'. 374 -- all that 'require "lanes"'.
375 -- 375 --
376 -- Linda protocol to timer lane: 376 -- Linda protocol to timer lane:
377 -- 377 --
378 -- TGW_KEY: linda_h, key, [wakeup_at_secs], [repeat_secs] 378 -- TGW_KEY: linda_h, key, [wakeup_at_secs], [repeat_secs]
@@ -403,7 +403,7 @@ lanes.configure = function( settings_)
403 local timer_body = function() 403 local timer_body = function()
404 set_debug_threadname( "LanesTimer") 404 set_debug_threadname( "LanesTimer")
405 -- 405 --
406 -- { [deep_linda_lightuserdata]= { [deep_linda_lightuserdata]=linda_h, 406 -- { [deep_linda_lightuserdata]= { [deep_linda_lightuserdata]=linda_h,
407 -- [key]= { wakeup_secs [,period_secs] } [, ...] }, 407 -- [key]= { wakeup_secs [,period_secs] } [, ...] },
408 -- } 408 -- }
409 -- 409 --
@@ -452,7 +452,7 @@ lanes.configure = function( settings_)
452 t1 = { [linda_deep] = linda} -- proxy to use the Linda 452 t1 = { [linda_deep] = linda} -- proxy to use the Linda
453 collection[linda_deep] = t1 453 collection[linda_deep] = t1
454 end 454 end
455 455
456 if wakeup_at == nil then 456 if wakeup_at == nil then
457 -- Clear the timer 457 -- Clear the timer
458 -- 458 --
@@ -482,7 +482,7 @@ lanes.configure = function( settings_)
482 t2= {} 482 t2= {}
483 t1[key]= t2 483 t1[key]= t2
484 end 484 end
485 485
486 t2[1] = wakeup_at 486 t2[1] = wakeup_at
487 t2[2] = period -- can be 'nil' 487 t2[2] = period -- can be 'nil'
488 end 488 end
@@ -507,12 +507,12 @@ lanes.configure = function( settings_)
507 local wakeup_at= t2[1] 507 local wakeup_at= t2[1]
508 local period= t2[2] -- may be 'nil' 508 local period= t2[2] -- may be 'nil'
509 509
510 if wakeup_at <= now then 510 if wakeup_at <= now then
511 local linda= t1[linda_deep] 511 local linda= t1[linda_deep]
512 assert(linda) 512 assert(linda)
513 513
514 linda:set( key, now ) 514 linda:set( key, now )
515 515
516 -- 'pairs()' allows the values to be modified (and even 516 -- 'pairs()' allows the values to be modified (and even
517 -- removed) as far as keys are not touched 517 -- removed) as far as keys are not touched
518 518
@@ -531,10 +531,10 @@ lanes.configure = function( settings_)
531 t2[1]= wakeup_at 531 t2[1]= wakeup_at
532 end 532 end
533 end 533 end
534 534
535 if wakeup_at and ((not next_wakeup) or (wakeup_at < next_wakeup)) then 535 if wakeup_at and ((not next_wakeup) or (wakeup_at < next_wakeup)) then
536 next_wakeup= wakeup_at 536 next_wakeup= wakeup_at
537 end 537 end
538 end 538 end
539 end -- t2 loop 539 end -- t2 loop
540 end -- t1 loop 540 end -- t1 loop