diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2020-11-05 20:55:25 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2020-11-05 20:55:25 +0800 |
commit | 6f927f4fa9a7c6e0446755a3f6aa86570c684754 (patch) | |
tree | ff86afad2f404c8df68233767fcbbe3d626acabd /script-beta/core/hover | |
parent | fe6f1115b5302ddd8ea7ed3e61a222d7294454d0 (diff) | |
download | lua-language-server-6f927f4fa9a7c6e0446755a3f6aa86570c684754.zip |
优化有大量全局变量时的性能
Diffstat (limited to 'script-beta/core/hover')
-rw-r--r-- | script-beta/core/hover/table.lua | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/script-beta/core/hover/table.lua b/script-beta/core/hover/table.lua index 899306dc..ff4012bb 100644 --- a/script-beta/core/hover/table.lua +++ b/script-beta/core/hover/table.lua @@ -228,13 +228,7 @@ return function (source) local clock = os.clock() local timeUp local mark = {} - local fields - if source.special == '_G' - and config.config.intelliSense.fastGlobal then - fields = vm.getGlobals('*', 'fast') - else - fields = vm.getFields(source, 'deep') - end + local fields = vm.getFields(source, 'deep') for _, src in ipairs(fields) do local key = getKey(src) if not key then |