From 59735a290454dbed385b9bdc0401323be3e0358e Mon Sep 17 00:00:00 2001 From: marty Date: Sun, 24 Feb 2008 00:31:27 +1300 Subject: [PATCH] bugfix: fixed a bug with &selection and visual commenting --- doc/NERD_commenter.txt | 4 ++++ plugin/NERD_commenter.vim | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/doc/NERD_commenter.txt b/doc/NERD_commenter.txt index 6a01546..1680d60 100644 --- a/doc/NERD_commenter.txt +++ b/doc/NERD_commenter.txt @@ -860,6 +860,10 @@ to get illegal syntax when uncommenting them. ============================================================================== 8. Changelog *NERDComChangelog* +2.1.11 + - fixed a bug with the selection option and visual commenting (again). + Thanks to Ingo Karkat (again). + 2.1.10 - added support for Wikipedia (thanks to Chen Xing) - added support for mplayerconf diff --git a/plugin/NERD_commenter.vim b/plugin/NERD_commenter.vim index 675b29e..b1d824c 100644 --- a/plugin/NERD_commenter.vim +++ b/plugin/NERD_commenter.vim @@ -1453,7 +1453,7 @@ function! NERDComment(isVisual, type) range let firstLine = line("'<") let lastLine = line("'>") let firstCol = col("'<") - let lastCol = col("'>") - (&selection == 'exclusive' && has("gui_running") ? 1 : 0) + let lastCol = col("'>") - (&selection == 'exclusive' ? 1 : 0) else let firstLine = a:firstline let lastLine = a:lastline