This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

vim paste bug with compatible and showmatch turned on (seen for at least a year)


64-bit Cygwin, Win10, nothing special about my installation.


Start vim cleanly inside a mintty window running bash (updated my installation today):
/usr/bin/vim --clean -u /dev/nul test.txt

Insert the following string:
"pIppp"

Copy that string into the paste buffer using the mouse and ctrl-insert.
Insert the following string on the next line:
"(char *) "

Then press shift-insert to paste. You should get:
"(char *) pIppp"

This is normal behavior.

Press escape and then ":set sm cp" and press enter  Vim is now in compatible mode and showmatch is turned on.

Insert the following string on the next line:
"(char *) "

Then press shift-insert to paste.  You should get the same string.  However, I get:
"Ppp(char *)"

It seems like at least an ESC character is inserted, so the mode gets changed from insert to command.  This can be really destructive if you have a long buffer.

The showmatch mechanism is required to reproduce this bug.

Is this bug a Cygwin, vim, mintty, or something else bug?

Thanks,Kevin



PS Yes, I use compatible mode because I am that old.

Attachment: cygcheck.out
Description: Binary data

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]