V15.3.0 #46
@ -1313,6 +1313,7 @@ function multi:attachScheduler()
|
|||||||
table.insert(threads,c)
|
table.insert(threads,c)
|
||||||
table.insert(startme,c)
|
table.insert(startme,c)
|
||||||
startme_len = #startme
|
startme_len = #startme
|
||||||
|
print("startme:",startme_len)
|
||||||
globalThreads[c] = self
|
globalThreads[c] = self
|
||||||
if initT==false then
|
if initT==false then
|
||||||
self.initThreads()
|
self.initThreads()
|
||||||
@ -1509,7 +1510,7 @@ function multi:attachScheduler()
|
|||||||
_,ret,r1,r2,r3,r4,r5,r6,r7,r8,r9,r10,r11,r12,r13,r14,r15,r16 = resume(startme[start].thread,unpack(startme[start].startArgs))
|
_,ret,r1,r2,r3,r4,r5,r6,r7,r8,r9,r10,r11,r12,r13,r14,r15,r16 = resume(startme[start].thread,unpack(startme[start].startArgs))
|
||||||
co_status[status(startme[startme_len].thread)](startme[startme_len].thread,startme[startme_len],t_none) --cmds[r1](startme[start],r2,r3,r4,r5)
|
co_status[status(startme[startme_len].thread)](startme[startme_len].thread,startme[startme_len],t_none) --cmds[r1](startme[start],r2,r3,r4,r5)
|
||||||
startme[startme_len] = nil
|
startme[startme_len] = nil
|
||||||
startme_len = startme_len - 1
|
startme_len = #startme
|
||||||
end
|
end
|
||||||
if threads[i] then
|
if threads[i] then
|
||||||
ref = threads[i]
|
ref = threads[i]
|
||||||
|
|||||||
@ -1,6 +1,9 @@
|
|||||||
package.path="multi/?.lua;multi/?/init.lua;multi/?.lua;multi/?/?/init.lua;"..package.path
|
if os.getenv("LOCAL_LUA_DEBUGGER_VSCODE") == "1" then
|
||||||
require("lldebugger").start()
|
package.path="multi/?.lua;multi/?/init.lua;multi/?.lua;multi/?/?/init.lua;"..package.path
|
||||||
|
require("lldebugger").start()
|
||||||
|
else
|
||||||
|
package.path="./?.lua;../?/init.lua;../?.lua;../?/?/init.lua;"..package.path
|
||||||
|
end
|
||||||
--[[
|
--[[
|
||||||
This file runs all tests.
|
This file runs all tests.
|
||||||
Format:
|
Format:
|
||||||
@ -17,8 +20,6 @@ require("lldebugger").start()
|
|||||||
The expected and actual should "match" (Might be impossible when playing with threads)
|
The expected and actual should "match" (Might be impossible when playing with threads)
|
||||||
This will be pushed directly to the master as tests start existing.
|
This will be pushed directly to the master as tests start existing.
|
||||||
]]
|
]]
|
||||||
os.execute("cd multi")
|
|
||||||
os.execute("pwd")
|
|
||||||
local multi, thread = require("multi"):init{priority=true}
|
local multi, thread = require("multi"):init{priority=true}
|
||||||
local good = false
|
local good = false
|
||||||
runTest = thread:newFunction(function()
|
runTest = thread:newFunction(function()
|
||||||
@ -38,7 +39,6 @@ runTest = thread:newFunction(function()
|
|||||||
require("tests/connectionTest")(conn_thread,thread)
|
require("tests/connectionTest")(conn_thread,thread)
|
||||||
conn_thread.Stop()
|
conn_thread.Stop()
|
||||||
--print(multi:getTasksDetails())
|
--print(multi:getTasksDetails())
|
||||||
os.exit()
|
|
||||||
end)
|
end)
|
||||||
runTest().OnError(function(...)
|
runTest().OnError(function(...)
|
||||||
print("Error:",...)
|
print("Error:",...)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user