diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2020-07-23 17:32:05 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2020-07-23 17:32:05 +0800 |
commit | 57c107a0ae92086b4cf2605efb8c108a525053f5 (patch) | |
tree | 3645b558ac7d1d2d43252a79d9e9808da2d8b73c /script-beta/core | |
parent | f345904350c074438b25941fb29d00eb4f84e7a0 (diff) | |
download | lua-language-server-57c107a0ae92086b4cf2605efb8c108a525053f5.zip |
穿透全局simple
Diffstat (limited to 'script-beta/core')
-rw-r--r-- | script-beta/core/completion.lua | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/script-beta/core/completion.lua b/script-beta/core/completion.lua index f1bc5a25..4792d7b8 100644 --- a/script-beta/core/completion.lua +++ b/script-beta/core/completion.lua @@ -179,6 +179,10 @@ local function buildFunction(results, source, oop, data) end local function isSameSource(source, pos) + if source.type == 'field' + or source.type == 'method' then + source = source.parent + end return source.start <= pos and source.finish >= pos end |