From 0c3e35427e70cf83178e338e854f70e9f8124bf9 Mon Sep 17 00:00:00 2001 From: fesily Date: Thu, 1 Jun 2023 10:22:23 +0800 Subject: Update compiler.lua --- script/vm/compiler.lua | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'script/vm') diff --git a/script/vm/compiler.lua b/script/vm/compiler.lua index 3927e359..6b4636fc 100644 --- a/script/vm/compiler.lua +++ b/script/vm/compiler.lua @@ -523,16 +523,7 @@ local function getReturnOfSetMetaTable(args) end) end --过滤nil - local len = #node - for i = len, 1, -1 do - local n = node[i] - if n.cate == 'type' then - if n.name == 'nil' then - table.remove(node, i) - break - end - end - end + node:remove 'nil' return node end -- cgit v1.2.3