diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2022-11-16 21:05:55 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2022-11-16 21:05:55 +0800 |
commit | 8d383d5d34ce25faa32f421560632de21239bed5 (patch) | |
tree | 2e0ec662a17f13fb08ad45d88260bf6ea88822c6 /script/vm | |
parent | e54fb73d81459fcee1e8402da422f56d00684921 (diff) | |
download | lua-language-server-8d383d5d34ce25faa32f421560632de21239bed5.zip |
add tests for recursive-runner
Diffstat (limited to 'script/vm')
-rw-r--r-- | script/vm/compiler.lua | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/script/vm/compiler.lua b/script/vm/compiler.lua index 2d7f2a69..6dbe41fe 100644 --- a/script/vm/compiler.lua +++ b/script/vm/compiler.lua @@ -6,8 +6,6 @@ local files = require 'files' ---@class vm local vm = require 'vm.vm' -local LOCK = {} - ---@class parser.object ---@field _compiledNodes boolean ---@field _node vm.node @@ -1213,25 +1211,6 @@ local compilerSwitch = util.switch() vm.setNode(src, vm.createNode(src.value)) vm.setNode(src, node:copy():asTable()) else - local function clearLockedNode(child) - if not child then - return - end - if child.type == 'function' then - return - end - if child.type == 'setlocal' - or child.type == 'getlocal' then - if child.node == source then - return - end - end - if LOCK[child] then - vm.removeNode(child) - end - guide.eachChild(child, clearLockedNode) - end - clearLockedNode(src.value) vm.setNode(src, vm.compileNode(src.value), true) end else @@ -1964,12 +1943,10 @@ function vm.compileNode(source) ---@cast source parser.object vm.setNode(source, vm.createNode(), true) - LOCK[source] = true compileByGlobal(source) compileByNode(source) compileByParentNode(source) matchCall(source) - LOCK[source] = nil local node = vm.getNode(source) ---@cast node -? |