diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2022-10-21 18:03:04 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2022-10-21 18:03:04 +0800 |
commit | 6030fd1ac2ae14810cff7fccf85a8ab95ab42c3d (patch) | |
tree | 7fc8f86e90a25a29f88547d3df1afaa57dae660e /script/workspace | |
parent | 480f2224cfbcd7c206f2853b28ae85f5acb4edad (diff) | |
download | lua-language-server-6030fd1ac2ae14810cff7fccf85a8ab95ab42c3d.zip |
多线程编译测试
Diffstat (limited to 'script/workspace')
-rw-r--r-- | script/workspace/loading.lua | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/script/workspace/loading.lua b/script/workspace/loading.lua index ff8626ed..43909357 100644 --- a/script/workspace/loading.lua +++ b/script/workspace/loading.lua @@ -88,7 +88,12 @@ function mt:loadFile(uri, libraryUri) self._cache[uri] = true log.debug(('Skip loaded file: %s'):format(uri)) else - local content = pub.awaitTask('loadFile', furi.decode(uri)) + local content + if COMPILECORES then + content = util.loadFile(furi.decode(uri)) + else + content = pub.awaitTask('loadFile', furi.decode(uri)) + end self.read = self.read + 1 self:update() if not content then |