Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reserve slots with false #52

Merged
merged 1 commit into from
Jun 15, 2022
Merged

Reserve slots with false #52

merged 1 commit into from
Jun 15, 2022

Conversation

tomtomjhj
Copy link
Contributor

@tomtomjhj tomtomjhj commented Jun 15, 2022

Maybe fixes #33, #44.

IIUC, nvim_buf_call in index_range defers the callback, so source.complete may observe (buf:get_words) the "reserved" slot with the dummy value vim.NIL. Change this value to false, so that self.lines_words[i] or {} does what we mean.

cc @dmitmel

@dmitmel
Copy link
Collaborator

dmitmel commented Jun 15, 2022

Good idea. LGTM.

@dmitmel dmitmel merged commit 62fc67a into hrsh7th:main Jun 15, 2022
@tomtomjhj tomtomjhj deleted the reserve branch June 15, 2022 18:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

buffer.lua:317: bad argument #1 to ipairs (table expected, got userdata)
2 participants