summaryrefslogtreecommitdiff
path: root/server/src/core
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2019-09-25 11:42:23 +0800
committer最萌小汐 <sumneko@hotmail.com>2019-09-25 11:42:23 +0800
commitf501deff48a30e937afdcb528aba942648c4888b (patch)
tree0656c12f5d035d59a33db6aee55169f5e97b4b4d /server/src/core
parent5e9f40d4666055c5998df0c3137db83127f5623b (diff)
downloadlua-language-server-f501deff48a30e937afdcb528aba942648c4888b.zip
修正未使用函数的透明着色位置错误的bug
Diffstat (limited to 'server/src/core')
-rw-r--r--server/src/core/diagnostics.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/server/src/core/diagnostics.lua b/server/src/core/diagnostics.lua
index e5fd0ba5..8584897e 100644
--- a/server/src/core/diagnostics.lua
+++ b/server/src/core/diagnostics.lua
@@ -73,7 +73,7 @@ function mt:searchUnusedFunctions(callback)
if info.type == 'set' or info.type == 'local' then
local v = src:bindValue()
local func = v and v:getFunction()
- if func then
+ if func and func:getSource().uri == self.vm.uri then
callback(func:getSource().start, func:getSource().finish)
end
end