mirror of
https://github.com/cloudwu/skynet.git
synced 2026-07-24 20:23:06 +00:00
bugfix last commit
This commit is contained in:
@@ -313,10 +313,12 @@ local function packgroup(t,p)
|
|||||||
local tt, tp
|
local tt, tp
|
||||||
local alltypes = {}
|
local alltypes = {}
|
||||||
for name in pairs(t) do
|
for name in pairs(t) do
|
||||||
alltypes[name] = #alltypes
|
|
||||||
table.insert(alltypes, name)
|
table.insert(alltypes, name)
|
||||||
end
|
end
|
||||||
table.sort(alltypes) -- make result stable
|
table.sort(alltypes) -- make result stable
|
||||||
|
for idx, name in ipairs(alltypes) do
|
||||||
|
alltypes[name] = idx - 1
|
||||||
|
end
|
||||||
tt = {}
|
tt = {}
|
||||||
for _,name in ipairs(alltypes) do
|
for _,name in ipairs(alltypes) do
|
||||||
table.insert(tt, packtype(name, t[name], alltypes))
|
table.insert(tt, packtype(name, t[name], alltypes))
|
||||||
|
|||||||
Reference in New Issue
Block a user