diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-11-14 11:41:47 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-11-14 11:41:47 +0800 |
commit | c7137ba14af910490a523d50c001098946ddf410 (patch) | |
tree | 489137fb25ec9c0dc39ab679ecd1d6d4c074bd6a /server/src/core | |
parent | 6b51351ecf215a09609e63a17209ac8757cc3844 (diff) | |
download | lua-language-server-c7137ba14af910490a523d50c001098946ddf410.zip |
多行字符串支持折行
Diffstat (limited to 'server/src/core')
-rw-r--r-- | server/src/core/folding_range.lua | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/server/src/core/folding_range.lua b/server/src/core/folding_range.lua index db0b0bdf..e94d1ffe 100644 --- a/server/src/core/folding_range.lua +++ b/server/src/core/folding_range.lua @@ -8,6 +8,7 @@ local foldingType = { ['while'] = {'region', 'end', }, ['repeat'] = {'region', 'until',}, ['table'] = {'region', '}', }, + ['string'] = {'regtion', ']', }, } return function (vm, comments) @@ -42,6 +43,12 @@ return function (vm, comments) kind = data[1], } end + elseif tp == 'string' then + result[#result+1] = { + start = start, + finish = finish, + kind = data[1], + } elseif data[1] == 'region' then result[#result+1] = { start = start, |