diff options
| author | Benoit Germain <benoit.germain@ubisoft.com> | 2025-06-05 16:03:22 +0200 |
|---|---|---|
| committer | Benoit Germain <benoit.germain@ubisoft.com> | 2025-06-05 16:03:22 +0200 |
| commit | bfdc7a92c4e3e99522abb6d90ef2cbb021f36fc8 (patch) | |
| tree | 00f6633878b21dda6cad1177d5619a501b4ac0a4 /tests/perftest.lua | |
| parent | f73702bcf4372a149b8b01a512c0e086b1e679e2 (diff) | |
| download | lanes-bfdc7a92c4e3e99522abb6d90ef2cbb021f36fc8.tar.gz lanes-bfdc7a92c4e3e99522abb6d90ef2cbb021f36fc8.tar.bz2 lanes-bfdc7a92c4e3e99522abb6d90ef2cbb021f36fc8.zip | |
Change lane:join() return values
* when no error is raised in the lane, lane:join() now precedes the lane returned values with true
* lane body is no longer forced to return something when used with join()
* adjusted all relevant unit tests accordingly
Diffstat (limited to 'tests/perftest.lua')
| -rw-r--r-- | tests/perftest.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/perftest.lua b/tests/perftest.lua index fe43cca..35e164d 100644 --- a/tests/perftest.lua +++ b/tests/perftest.lua | |||
| @@ -175,9 +175,9 @@ else | |||
| 175 | -- Make sure all lanes finished | 175 | -- Make sure all lanes finished |
| 176 | -- | 176 | -- |
| 177 | for i=1,N do | 177 | for i=1,N do |
| 178 | local tmp= t[i]:join() | 178 | local r, tmp = t[i]:join() |
| 179 | -- this assert will trigger if you change M to values below 1000 in order to solve C stack overflow | 179 | -- this assert will trigger if you change M to values below 1000 in order to solve C stack overflow |
| 180 | assert( type(tmp)=="table" and tmp[1]==2 and tmp[168]==997 ) | 180 | assert( r == true and type(tmp) == "table" and tmp[1] == 2 and tmp[168] == 997 ) |
| 181 | end | 181 | end |
| 182 | end | 182 | end |
| 183 | 183 | ||
