String foo = "foobarbaz" ;foobarbaz, and then type va"String foo = "foobarbaz";foobarbaz, and then type va".In the first example, I expect only "foobarbaz" to be highlighted. However, the trailing whitespace between the " and ; is also highlighted.

In the second example, I expect only "foobarbaz" to be highlighted. However, the trailing whitespace before the = and " is also highlighted.

To be honest, I'm not sure whether this is a bug or not. I did some searching online to find out more about this behavior, but was not able to find what I was looking for. I decided that it would be best to open an issue here to see if this is expected behavior or not.
I came across the same behavior on NVIM v0.7.2 and VSCodeVim/Vim v.1.24.1. Only on IdeaVim 1.11.1, did I see the behavior I was expecting. My impression was that this command was supposed to only highlight the text + specified character, rather than include the whitespace around it.
I also find it strange that only trailing or preceding whitespace is be included, rather than both. When there is trailing whitespace, only that is included; otherwise, the preceding whitespace is included.
Specifically, this happens for va", va', va`. This does not happen for va(, va{, va[, va<.
I would greatly appreciate it if somebody could get back to me and inform me whether this is a bug, or expected behavior. If it is a bug, I would be glad to work on a fix and contribute to Vim!
9.0
Operating System: Fedora Linux 36 (Workstation Edition)
Terminal: GNOME Terminal 3.44.1
Value of $TERM: xterm-256color
Shell: zsh 5.8.1
No response
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
Closed #11338 as completed.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()
Well, I should have read the manual first. This is actually expected behavior, and what I want would be something like v2i", to highlight the quotes without the whitespace. While I'm still curious as to why this behavior exists, I understand this is not a bug. I will close my issue.
—
Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.![]()