kana / vim-textobj-line

Vim plugin: Text objects for the current line
http://www.vim.org/scripts/script.php?script_id=3886
178 stars 7 forks source link

Marks '< and '> being clobbered #6

Closed Asheq closed 7 years ago

Asheq commented 7 years ago

First off, I love this text object. I use yil (yank in line) all the time.

I'm experiencing a minor problem, however. When I invoke yil, it overwrites the '< and '> marks. These marks are standard marks that indicate the first and last character of the previously visually-selected area. I don't expect yil to change these marks. I think yil should behave like built-in commands like yiw, which leave these marks alone.

I imagine that the plugin is visually selecting the text object in the background. Is there any way to do that without the side effect of changing '< and '>? Maybe by saving them and restoring them before the function completes?

Thanks

kana commented 7 years ago

Thank you for the report. I'll look into later.

kana commented 7 years ago

I've looked into the problem. It is a common problem for all vim-textobj-user based plugins. I'll try to fix later.

kana commented 7 years ago

I've fixed the problem. Please update vim-textobj-user.

Asheq commented 7 years ago

Looks like it's working for me. Thanks for the prompt fix!