Fix entry offset calculation
This commit is contained in:
@@ -34,7 +34,7 @@ entry.new = function(ctx, source, completion_item)
|
||||
self.score = 0
|
||||
self.context = ctx
|
||||
self.source = source
|
||||
self.source_offset = source.offset
|
||||
self.source_offset = source.request_offset
|
||||
self.source_insert_range = source:get_default_insert_range()
|
||||
self.source_replace_range = source:get_default_replace_range()
|
||||
self.completion_item = completion_item
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
local debug = {}
|
||||
|
||||
local flag = false
|
||||
debug.flag = false
|
||||
|
||||
---Print log
|
||||
---@vararg any
|
||||
debug.log = function(...)
|
||||
if flag then
|
||||
if debug.flag then
|
||||
local data = {}
|
||||
for _, v in ipairs({ ... }) do
|
||||
if not vim.tbl_contains({ 'string', 'number', 'boolean' }, type(v)) then
|
||||
|
||||
Reference in New Issue
Block a user