diff options
Diffstat (limited to 'script/vm/global.lua')
-rw-r--r-- | script/vm/global.lua | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/script/vm/global.lua b/script/vm/global.lua index 5f32cd87..f9090893 100644 --- a/script/vm/global.lua +++ b/script/vm/global.lua @@ -521,10 +521,15 @@ function vm.compileByGlobal(source) if global.cate == 'variable' then vm.setNode(source, global) if guide.isAssign(source) then - vm.setNode(source, vm.compileNode(source.value)) + if source.value then + vm.setNode(source, vm.compileNode(source.value)) + end return end - vm.traceNode(source) + local node = vm.traceNode(source) + if node then + vm.setNode(source, node, true) + end return end local globalBase = vm.getGlobalBase(source) |