summaryrefslogtreecommitdiff
path: root/script/core
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2021-09-18 17:28:21 +0800
committer最萌小汐 <sumneko@hotmail.com>2021-09-18 17:28:21 +0800
commitb45a90132438bb2d84b7376066e5ff409833a13f (patch)
treeb87782402cd4c5f275aa880d1c9bd82b5b5b1103 /script/core
parenta7fcbe21fa6e06c46875fd8abb6d2eacb1db844e (diff)
downloadlua-language-server-b45a90132438bb2d84b7376066e5ff409833a13f.zip
update
Diffstat (limited to 'script/core')
-rw-r--r--script/core/completion.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/script/core/completion.lua b/script/core/completion.lua
index e37dceed..51f1087e 100644
--- a/script/core/completion.lua
+++ b/script/core/completion.lua
@@ -1884,14 +1884,14 @@ local function tryLuaDoc(state, text, position, results)
return
end
if doc.type == 'doc.comment' then
- local line = text:sub(doc.start, doc.range)
+ local line = doc.originalComment.text
-- 尝试 ---$
if line == '-' then
tryLuaDocOfFunction(doc, results)
return
end
-- 尝试 ---@$
- local cate = line:match('^-%s*@(%a*)$')
+ local cate = line:match('^-+%s*@(%a*)$')
if cate then
tryLuaDocCate(cate, results)
return