summaryrefslogtreecommitdiff
path: root/server/src/parser/ast.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2019-11-14 11:35:52 +0800
committer最萌小汐 <sumneko@hotmail.com>2019-11-14 11:35:52 +0800
commit6b51351ecf215a09609e63a17209ac8757cc3844 (patch)
treecc014b6beb7438be735168a3eecf2792bf393627 /server/src/parser/ast.lua
parenta1a5e4da0d5b1f994117d8e51ea7e105cca7d049 (diff)
downloadlua-language-server-6b51351ecf215a09609e63a17209ac8757cc3844.zip
多行注释支持折行
Diffstat (limited to 'server/src/parser/ast.lua')
-rw-r--r--server/src/parser/ast.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/server/src/parser/ast.lua b/server/src/parser/ast.lua
index 3d8b8ed8..38cd8576 100644
--- a/server/src/parser/ast.lua
+++ b/server/src/parser/ast.lua
@@ -271,7 +271,11 @@ local Defs = {
[1] = false,
}
end,
- LongComment = function (beforeEq, afterEq, str, missPos)
+ LongComment = function (beforeEq, afterEq, str, finish, missPos)
+ State.Comments[#State.Comments+1] = {
+ start = beforeEq,
+ finish = finish,
+ }
if missPos then
local endSymbol = ']' .. ('='):rep(afterEq-beforeEq) .. ']'
local s, _, w = str:find('(%][%=]*%])[%c%s]*$')