-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
insert mode . is sometimes mapped to ESC*i by YCM #2698
Comments
Could you fill the rest of the issue template? That would be helpful. |
I mean the full output of |
https://gist.github.com/screwzm/bd4b8cbddb79c160c8ff635969e4625e vim version gist @micbou |
@micbou All the required debug info is available here . https://gist.github.com/screwzm/4f86766730726e612c3070b9334178f6 |
No map of . is found side vim :imap though .. This is very annoying.. |
@screwzm So could you try a clean YCM/ycmd install? |
@bstaletic I didi tried clean install , and the error remains under clean & successful build.. |
Found the issue. This is caused by the default Vim omnifunc for C-family languages ( |
[READY] Restore cursor position after omnifunc call When compiled without C-family support, YCM will use the default omnifunc from Vim (`ccomplete#Complete`) to provide semantic completion. This omnifunc calls [`searchdecl`](http://vimdoc.sourceforge.net/htmldoc/eval.html#searchdecl()) to find a declaration, which is supposed to move the cursor to that declaration. However, the cursor is not moved when called through the omni completion mapping (`CTRL-X CTRL-O`). Since PR #2657, YCM calls the omnifunc outside completion mode and thus the cursor is moved to the found declaration after typing `.` or `->`. Considering this `searchdecl` trick may be used by other omnifuncs, we fix the issue by always restoring the cursor position after calling the omnifunc. Fixes #2698. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/valloric/youcompleteme/2707) <!-- Reviewable:end -->
@screwzm Can you confirm this is fixed with the latest version of YCM? |
@micbou This issue was fixed by the new merge.. Thanks . |
Issue Prelude
Please complete these steps and check these boxes (by putting an
x
insidethe brackets) before filing your issue:
Frequently Asked Questions section.
about to report and couldn't find an answer to my problem. (Example Google
search.)
vim --version
.:YcmDebugInfo
.the
:YcmToggleLogs
command.version) I am using.
my issue, including what I expected to happen and what actually happened.
of
install.py
(orcmake
/make
/ninja
) including its invocationthat any help I receive is a selfless, heartfelt gift of their free time. I
know I am not entitled to anything and will be polite and courteous.
actually perform all of these steps.
Thank you for adhering to this process! It ensures your issue is resolved
quickly and that neither your nor our time is needlessly wasted.
Issue Details
a raw char . is input after 0 without any side effects
After long investigation, I found that the . is sometimes mapled by YCM to ESC*i in vim insert mode.
Diagnostic data
Output of
vim --version
VIM - Vi IMproved 8.0 (2016 Sep 12, compiled Apr 26 2017 13:40:28)
Output of
YcmDebugInfo
Contents of YCM, ycmd and completion engine logfiles
OS version, distribution, etc.
Linux middlebury 4.4.0-81-generic #104~14.04.1-Ubuntu SMP Wed Jun 14 12:45:52 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Output of build/install commands
The text was updated successfully, but these errors were encountered: