From 9b78a51e6eb060ce0bee664d18facc656135035a Mon Sep 17 00:00:00 2001
From: Benoit Germain
The name is stored inside the Lua state registry so that it is available for error reporting. Changing decoda_name doesn't affect this hidden name or the OS thread name reported by MSVC.
When Lanes is initialized by the first lanes.configure() call, "main" is stored in the registry in the same fashion (but decoda_name and the OS thread name are left unchanged).
- The lane also has a method lane:get_debug_threadname() that gives access to that name from the caller side (returns "<unnamed>" if unset, "<closed>" if the internal Lua state is closed).
+ The lane also has a method lane:get_debug_threadname() that gives access to that name from the caller side (returns "<unnamed>" if unset, "<closed>" if the internal Lua state is closed).
+ With Lua 5.4, Lanes have a __close metamethod, meaning they can be declared to-be-closed. __close calls lane:join(nil).
@@ -986,12 +987,11 @@
- [...]|[nil,err,stack_tbl]= lane_h:join([timeout_secs]) + [...]|[nil,err,stack_tbl]= lane_h:join([timeout]) |
- timeout is an optional number >= 0 (the default if unspecified).
- Waits until the lane finishes, or timeout seconds have passed.
+ Waits until the lane finishes, or timeout seconds have passed (forever if nil).
Unlike in reading the results in table fashion, errors are not propagated.
Possible return values are: