From df3f1879b0a0a7debf488aa89b98cc969bbfe5af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=80=E8=90=8C=E5=B0=8F=E6=B1=90?= Date: Wed, 30 Dec 2020 11:09:43 +0800 Subject: some fix --- script/provider/provider.lua | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'script/provider/provider.lua') diff --git a/script/provider/provider.lua b/script/provider/provider.lua index 32778399..c71b14fa 100644 --- a/script/provider/provider.lua +++ b/script/provider/provider.lua @@ -35,6 +35,10 @@ local function updateConfig() } }, }) + if not configs or not configs[1] then + log.warn('No config?', util.dump(configs)) + return + end local updated = configs[1] local other = { @@ -42,11 +46,6 @@ local function updateConfig() exclude = configs[3], } - if not updated then - log.warn('No config?', util.dump(configs)) - return - end - local oldConfig = util.deepCopy(config.config) local oldOther = util.deepCopy(config.other) config.setConfig(updated, other) -- cgit v1.2.3 From 69ddc8410def956d75d6429befbc2d1872fb6af7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=80=E8=90=8C=E5=B0=8F=E6=B1=90?= Date: Wed, 30 Dec 2020 11:59:43 +0800 Subject: refresh semantic tokens --- script/provider/provider.lua | 2 ++ 1 file changed, 2 insertions(+) (limited to 'script/provider/provider.lua') diff --git a/script/provider/provider.lua b/script/provider/provider.lua index c71b14fa..6512f1e7 100644 --- a/script/provider/provider.lua +++ b/script/provider/provider.lua @@ -54,6 +54,7 @@ local function updateConfig() if not util.equal(oldConfig.runtime, newConfig.runtime) then library.init() workspace.reload() + semantic.refresh() end if not util.equal(oldConfig.diagnostics, newConfig.diagnostics) then diagnostics.diagnosticsAll() @@ -66,6 +67,7 @@ local function updateConfig() or not util.equal(oldOther.exclude, newOther.exclude) then workspace.reload() + semantic.refresh() end if not util.equal(oldConfig.intelliSense, newConfig.intelliSense) then files.flushCache() -- cgit v1.2.3 From ee6fc1dd36ab448a6d3e1d9a3d2c0089bf2b678e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=80=E8=90=8C=E5=B0=8F=E6=B1=90?= Date: Thu, 31 Dec 2020 17:57:21 +0800 Subject: close #311 generate function documentation --- script/provider/provider.lua | 1 + 1 file changed, 1 insertion(+) (limited to 'script/provider/provider.lua') diff --git a/script/provider/provider.lua b/script/provider/provider.lua index 6512f1e7..2d092002 100644 --- a/script/provider/provider.lua +++ b/script/provider/provider.lua @@ -380,6 +380,7 @@ proto.on('textDocument/completion', function (params) kind = res.kind, deprecated = res.deprecated, sortText = ('%04d'):format(i), + filterText = res.filterText, insertText = res.insertText, insertTextFormat = 2, commitCharacters = res.commitCharacters, -- cgit v1.2.3