The main thread cannot be closed
No thread started with pcall (instead of resume) can be closed, because coroutine.close would not respect the expected number of results from the protected call.
This commit is contained in:
1 parent
fd897027f1
commit
e657a48ea5
3 files changed
+10
-2
No files matched your search
+2
-2
@@ -3284,8 +3284,8 @@ If @id{L} is equal to @id{from},
|
||||
it corresponds to a thread closing itself.
|
||||
In that case,
|
||||
the call does not return;
|
||||
instead, the resume or the protected call
|
||||
that (re)started the thread returns.
|
||||
instead, the resume that (re)started the thread returns.
|
||||
The thread must be running inside a resume.
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user