diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-11-02 17:48:37 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-11-02 17:48:37 +0800 |
commit | 1d099da37d10c5d9272780a4b85a212ef1f876aa (patch) | |
tree | 5773fb3c7fdbcc6f9b0f2509361da6cd0c920290 /server-beta/src/searcher/eachRef.lua | |
parent | d2d26defedebff9f036ef37c198bd27ceadbb9e9 (diff) | |
download | lua-language-server-1d099da37d10c5d9272780a4b85a212ef1f876aa.zip |
修正2个bug
Diffstat (limited to 'server-beta/src/searcher/eachRef.lua')
-rw-r--r-- | server-beta/src/searcher/eachRef.lua | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/server-beta/src/searcher/eachRef.lua b/server-beta/src/searcher/eachRef.lua index 6e5703a7..91acb403 100644 --- a/server-beta/src/searcher/eachRef.lua +++ b/server-beta/src/searcher/eachRef.lua @@ -109,6 +109,9 @@ end --- 自己作为函数的参数 local function asArg(searcher, source, callback) local parent = source.parent + if not parent then + return + end if parent.type == 'callargs' then local call = parent.parent local func = call.node @@ -234,6 +237,9 @@ end local function ofLiteral(searcher, source, callback) local parent = source.parent + if not parent then + return + end if parent.type == 'setindex' or parent.type == 'getindex' then ofField(searcher, source, callback) |