File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed
Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ local maxinterger = 10000
2020local mathType = math.type
2121local _G = _G
2222local registry = getregistry ()
23+ local ccreate = coroutine.create
2324
2425_ENV = nil
2526
@@ -449,6 +450,20 @@ m.snapshot = private(function ()
449450 info = find (_G ),
450451 }
451452 end
453+ for name , mt in next , private {
454+ [' nil' ] = getmetatable (nil ),
455+ [' boolean' ] = getmetatable (true ),
456+ [' number' ] = getmetatable (0 ),
457+ [' string' ] = getmetatable (' ' ),
458+ [' function' ] = getmetatable (function () end ),
459+ [' thread' ] = getmetatable (ccreate (function () end )),
460+ } do
461+ result .info [# result .info + 1 ] = private {
462+ type = ' metatable' ,
463+ name = name ,
464+ info = find (mt ),
465+ }
466+ end
452467 if m ._cache then
453468 m ._lastCache = result
454469 end
You can’t perform that action at this time.
0 commit comments