diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2018-12-03 14:05:41 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2018-12-03 14:05:41 +0800 |
commit | a17ae2a2d51e2decce0c793771a52999a1953270 (patch) | |
tree | 7b31795c58796307d8f8361df728fc119995dc72 /server/src | |
parent | 5fae702e4e7a6536170417718e56cfbebf42e4d7 (diff) | |
download | lua-language-server-a17ae2a2d51e2decce0c793771a52999a1953270.zip |
还是要遍历下去
Diffstat (limited to 'server/src')
-rw-r--r-- | server/src/matcher/definition.lua | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/server/src/matcher/definition.lua b/server/src/matcher/definition.lua index a7221f29..4b7b04c5 100644 --- a/server/src/matcher/definition.lua +++ b/server/src/matcher/definition.lua @@ -132,11 +132,11 @@ end function mt:searchSimple(simple) local name = simple[1] - if name.type ~= 'name' then - return + local var + if name.type == 'name' then + var = self:getVar(name[1], name) + self:checkVar(var, name) end - local var = self:getVar(name[1], name) - self:checkVar(var, name) for i = 2, #simple do local obj = simple[i] local tp = obj.type |