diff options
Diffstat (limited to 'server-beta/src')
-rw-r--r-- | server-beta/src/proto/define.lua | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/server-beta/src/proto/define.lua b/server-beta/src/proto/define.lua index 1bf45531..62c85989 100644 --- a/server-beta/src/proto/define.lua +++ b/server-beta/src/proto/define.lua @@ -43,10 +43,12 @@ end ---@param offset1 integer ---@param offset2 integer function m.range(lines, text, offset1, offset2) - return { - start = m.position(lines, text, offset1-1), + local range = { + start = m.position(lines, text, offset1), ['end'] = m.position(lines, text, offset2), } + range.start.character = range.start.character - 1 + return range end ---@alias location table |