Closed ELLIOTTCABLE closed 5 years ago
I've been a little hesitant to fix this because I'm not crazy about having filetype-specific criteria in the main pairing functions. However, I think Vim's unfortunate comment prefix makes this necessary. Right now I think I will make it so that "
is matched unless:
The cursor is on an empty line, or
The cursor follows more than one whitespace character.
This would handle end-of-line comments so long as the user precedes them with multiple spaces, and would still auto-pair "
for most cases where it is intended as a string delimiter.
I've also considered simply disabling "
matching in Vim files entirely via a ftplugin, but this might not be ideal from a user perspective. Feedback is welcome.
At the moment, pear-tree makes writing VimL really annoying — it tries to pair the initial quote of a Vim comment. Some sort of heuristic may be a good plan here!