diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-03-27 15:03:17 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-03-27 15:03:17 +0800 |
commit | b6a0f2e122d6821ce211ccd0f8c73bf95d0f7491 (patch) | |
tree | 7ab9c5a6286136814852688cdaf1f243b65a477b /server/src/core | |
parent | fcd29ea768e014a2284c3e991a0310b3708b6408 (diff) | |
download | lua-language-server-b6a0f2e122d6821ce211ccd0f8c73bf95d0f7491.zip |
统计持有函数
Diffstat (limited to 'server/src/core')
-rw-r--r-- | server/src/core/diagnostics.lua | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/server/src/core/diagnostics.lua b/server/src/core/diagnostics.lua index 7ebe297a..241d70ba 100644 --- a/server/src/core/diagnostics.lua +++ b/server/src/core/diagnostics.lua @@ -245,7 +245,11 @@ function mt:doDiagnostics(func, code, callback) self.datas[#self.datas+1] = data end) if coroutine.isyieldable() then - coroutine.yield() + if self.vm:isRemoved() then + coroutine.yield('stop') + else + coroutine.yield() + end end end |