create two entries in posmap for multi-line lines

This commit is contained in:
leaf corcoran 2014-03-05 23:18:15 -08:00
parent db8f5398fc
commit 3b81b84a9a
2 changed files with 3 additions and 0 deletions

View File

@ -61,6 +61,7 @@ do
local _exp_0 = mtype(l)
if "string" == _exp_0 or DelayedLine == _exp_0 then
line_no = line_no + 1
out[line_no] = posmap[i]
for _ in l:gmatch("\n") do
line_no = line_no + 1
end

View File

@ -44,6 +44,8 @@ class Lines
switch mtype l
when "string", DelayedLine
line_no += 1
out[line_no] = posmap[i]
line_no += 1 for _ in l\gmatch"\n"
out[line_no] = posmap[i]
when Lines