diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-03-12 15:08:43 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-03-12 15:08:43 +0800 |
commit | 095984fc21264c4c13f785ef833d4711034dc28f (patch) | |
tree | 4ec3df7224bb5130b433301733c08eb6213df54e /server | |
parent | 9efa5581ec3c628694c71c77970e769b83b31b00 (diff) | |
download | lua-language-server-095984fc21264c4c13f785ef833d4711034dc28f.zip |
调整诊断策略
Diffstat (limited to 'server')
-rw-r--r-- | server/src/service.lua | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/server/src/service.lua b/server/src/service.lua index bb8f59b1..4141b172 100644 --- a/server/src/service.lua +++ b/server/src/service.lua @@ -468,9 +468,13 @@ function mt:_createCompileTask() if uri then self:compileVM(uri) end - local uri = next(self._needDiagnostics) - if uri then + if self._needDiagnostics[uri] then self:doDiagnostics(uri) + else + uri = next(self._needDiagnostics) + if uri then + self:doDiagnostics(uri) + end end end) end |