Closed hrsh7th closed 3 years ago
Thank you! I don’t exactly understand why this change was necessary though. Maybe I have to read the LSP spec more closely.
some of the text \pi#
(# is cursor)
In this case, your specified keyword pattern will detects pi
as the replacing range (it does not includes \
)
So if the item confirmed, \
is not replacing.
New implementation contains \
as word, so nvim-cmp automatically detect \pi
as the replacing range.
Anyway, it is works now but I recommend specifying \\[^[:blank:]]*
as keyword pattern.
Thanks for the suggestion. The exact keyword pattern you suggested doesn't work (I believe it is invalid syntax), but I moved the last closing bracket and that seems to work. I've made a PR with that change.
I'm actually getting some odd behavior with trigger for the keyword pattern:
\sum<CR> -> ∑ -- Works as expected
\sum \s -- Auto complete does not trigger
https://user-images.githubusercontent.com/1813121/131003487-665a182f-e22a-4ff6-bd8e-adbeadc51157.mov
This is happening regardless of the old or new keyword pattern. I think this didn't happen before. Maybe another bug? Should I report this upstream?
This PR fixes https://github.com/hrsh7th/nvim-cmp/issues/83