cmp-vimtex
cmp-vimtex copied to clipboard
parser.timer breaks blink.cmp
Since parser.timer is a userdata type, it can't be copied, which stops blink.cmp from providing accepting completion items, since it deepcopies those items. If instead of parser.new containing self.timer = timer.new() you could modify parser.start_parsing to be
local t = timer.new()
t:start(0, 50, function()
...
t:stop()
::finish::
end)
Which (I believe) provides the same functionality without carrying the timer around everywhere you go.
Thanks for contributing. Unfortunately, I don't use blink.cmp and, as I really don't have available time at the moment, I won't be able to take a look at this.
If you'd like to open a PR I may do so, though; sorry.