summaryrefslogtreecommitdiff
path: root/script/parser/lines.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-09-07 16:28:31 +0800
committer最萌小汐 <sumneko@hotmail.com>2022-09-07 16:28:31 +0800
commita815d3f8c22cbbb44c3977cf73f87943283c213c (patch)
treeb0c1a89008db3b8da20e8aa00536c1d07774476c /script/parser/lines.lua
parentefe82edce8af8160c3a6e0977bee935f7f8655d5 (diff)
downloadlua-language-server-a815d3f8c22cbbb44c3977cf73f87943283c213c.zip
fix #1529
Diffstat (limited to 'script/parser/lines.lua')
-rw-r--r--script/parser/lines.lua1
1 files changed, 1 insertions, 0 deletions
diff --git a/script/parser/lines.lua b/script/parser/lines.lua
index 964aabf4..ffd021e6 100644
--- a/script/parser/lines.lua
+++ b/script/parser/lines.lua
@@ -6,6 +6,7 @@ return function (text)
local current = 1
local lines = {}
lines[0] = 1
+ lines.size = #text
local i = 0
while true do
local pos = sfind(text,'[\r\n]', current)