summaryrefslogtreecommitdiff
path: root/script/core/command
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2021-11-02 19:25:37 +0800
committer最萌小汐 <sumneko@hotmail.com>2021-11-02 19:25:37 +0800
commit36a5c10b00160c85a8c29170b5d5de8b27b4a5c9 (patch)
treef6db7d3d69bc24fecf16f3a3439d489dc5c43bf9 /script/core/command
parentc16264eac3b25f6f2bce14b0504071787bd2bc54 (diff)
downloadlua-language-server-36a5c10b00160c85a8c29170b5d5de8b27b4a5c9.zip
mark async
Diffstat (limited to 'script/core/command')
-rw-r--r--script/core/command/autoRequire.lua2
-rw-r--r--script/core/command/jsonToLua.lua1
-rw-r--r--script/core/command/removeSpace.lua1
-rw-r--r--script/core/command/solve.lua1
4 files changed, 5 insertions, 0 deletions
diff --git a/script/core/command/autoRequire.lua b/script/core/command/autoRequire.lua
index ca8826d7..30bd13a1 100644
--- a/script/core/command/autoRequire.lua
+++ b/script/core/command/autoRequire.lua
@@ -63,6 +63,7 @@ local function findInsertRow(uri)
return row or 0, fmt
end
+---@async
local function askAutoRequire(visiblePaths)
local selects = {}
local nameMap = {}
@@ -125,6 +126,7 @@ local function applyAutoRequire(uri, row, name, result, fmt)
})
end
+---@async
return function (data)
local uri = data.uri
local target = data.target
diff --git a/script/core/command/jsonToLua.lua b/script/core/command/jsonToLua.lua
index 6aecee2c..d29ad608 100644
--- a/script/core/command/jsonToLua.lua
+++ b/script/core/command/jsonToLua.lua
@@ -7,6 +7,7 @@ local lang = require 'language'
local converter = require 'proto.converter'
local guide = require 'parser.guide'
+---@async
return function (data)
local state = files.getState(data.uri)
local text = files.getText(data.uri)
diff --git a/script/core/command/removeSpace.lua b/script/core/command/removeSpace.lua
index 3021d4a4..aa565f7f 100644
--- a/script/core/command/removeSpace.lua
+++ b/script/core/command/removeSpace.lua
@@ -12,6 +12,7 @@ local function isInString(ast, offset)
end) or false
end
+---@async
return function (data)
local uri = data.uri
local text = files.getText(uri)
diff --git a/script/core/command/solve.lua b/script/core/command/solve.lua
index 9428d065..19148092 100644
--- a/script/core/command/solve.lua
+++ b/script/core/command/solve.lua
@@ -27,6 +27,7 @@ local literalMap = {
['table'] = true,
}
+---@async
return function (data)
local uri = data.uri
local text = files.getText(uri)