aboutsummaryrefslogtreecommitdiff
path: root/relabel.lua
diff options
context:
space:
mode:
Diffstat (limited to 'relabel.lua')
-rw-r--r--relabel.lua3
1 files changed, 1 insertions, 2 deletions
diff --git a/relabel.lua b/relabel.lua
index df5c8c8..f4f4546 100644
--- a/relabel.lua
+++ b/relabel.lua
@@ -285,8 +285,7 @@ end
285local function calcline (s, i) 285local function calcline (s, i)
286 if i == 1 then return 1, 1 end 286 if i == 1 then return 1, 1 end
287 local rest, line = s:sub(1,i):gsub("[^\n]*\n", "") 287 local rest, line = s:sub(1,i):gsub("[^\n]*\n", "")
288 local col = #rest 288 return 1 + line, #rest + 1
289 return 1 + line, col ~= 0 and col or 1
290end 289end
291 290
292 291