diff options
author | Alexey Melnichuk <alexeymelnichuck@gmail.com> | 2017-03-23 10:56:26 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-23 10:56:26 +0300 |
commit | 91b24571b3e00324460fc45a9a80cda02b59e485 (patch) | |
tree | 7557ef686824831540131b1614be576c63eec8dd | |
parent | 2c5f337169b6377cd43e699f557f46846ccdde7b (diff) | |
download | lua-llthreads2-91b24571b3e00324460fc45a9a80cda02b59e485.tar.gz lua-llthreads2-91b24571b3e00324460fc45a9a80cda02b59e485.tar.bz2 lua-llthreads2-91b24571b3e00324460fc45a9a80cda02b59e485.zip |
Update README.md
-rw-r--r-- | README.md | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -6,13 +6,13 @@ lua-llthreads2 | |||
6 | 6 | ||
7 | This is full dropin replacement for [llthreads](https://github.com/Neopallium/lua-llthreads) library. | 7 | This is full dropin replacement for [llthreads](https://github.com/Neopallium/lua-llthreads) library. |
8 | 8 | ||
9 | ##Incompatibility list with origin llthreads library | 9 | ## Incompatibility list with origin llthreads library |
10 | * does not support Lua 5.0 | 10 | * does not support Lua 5.0 |
11 | * does not support ffi interface (use Lua C API for LuaJIT) | 11 | * does not support ffi interface (use Lua C API for LuaJIT) |
12 | * returns nil instead of false on error | 12 | * returns nil instead of false on error |
13 | * start method returns self instead of true on success | 13 | * start method returns self instead of true on success |
14 | 14 | ||
15 | ##Additional | 15 | ## Additional |
16 | * thread:join() method support zero timeout to check if thread alive (does not work on Windows with pthreads) | 16 | * thread:join() method support zero timeout to check if thread alive (does not work on Windows with pthreads) |
17 | * thread:join() method support arbitrary timeout on Windows threads | 17 | * thread:join() method support arbitrary timeout on Windows threads |
18 | * thread:alive() method return whether the thread is alive (does not work on Windows with pthreads) | 18 | * thread:alive() method return whether the thread is alive (does not work on Windows with pthreads) |
@@ -20,16 +20,16 @@ This is full dropin replacement for [llthreads](https://github.com/Neopallium/lu | |||
20 | * thread:start() has additional parameter which control in which thread child Lua VM will be destroyed | 20 | * thread:start() has additional parameter which control in which thread child Lua VM will be destroyed |
21 | * allow pass cfunctions to child thread (e.g. to initialize Lua state) | 21 | * allow pass cfunctions to child thread (e.g. to initialize Lua state) |
22 | 22 | ||
23 | ##Thread start arguments | 23 | ## Thread start arguments |
24 | | `detached` | `joinable` | join returns | child state closes by | gc calls | detach on | | 24 | | `detached` | `joinable` | join returns | child state closes by | gc calls | detach on | |
25 | |:----------:|:----------:|:------------:|:---------------------:|:--------:|:---------:| | 25 | |:----------:|:----------:|:------------:|:---------------------:|:--------:|:---------:| |
26 | | false | false | `true` | child | join | `<NEVER>` | | 26 | | false | false | `true` | child | join | `<NEVER>` | |
27 | | false(*) | true(*) | Lua values | parent | join | `<NEVER>` | | 27 | | false(\*)| true(\*) | Lua values | parent | join \* | `<NEVER>` | |
28 | | true | false(*) | raise error | child | `<NONE>` | start | | 28 | | true | false(\*) | raise error | child | `<NONE>` | start | |
29 | | true | true | `true` | child | detach | gc | | 29 | | true | true | `true` | child | detach | gc | |
30 | 30 | ||
31 | 31 | ||
32 | ##Usage | 32 | ## Usage |
33 | 33 | ||
34 | ### Use custom logger | 34 | ### Use custom logger |
35 | In this example I use [lua-log](https://github.com/moteus/lua-log) library. | 35 | In this example I use [lua-log](https://github.com/moteus/lua-log) library. |