mirror of
https://github.com/preservim/nerdcommenter.git
synced 2025-11-11 11:13:47 -05:00
bugfix: fixed single line compact sexy comments
This commit is contained in:
@@ -875,6 +875,7 @@ to get illegal syntax when uncommenting them.
|
||||
comments arent possible with the filetypes delimiters
|
||||
- fixed some other bugs with sexy comments
|
||||
- made toggle commenting slightly more robust
|
||||
- fixed a bug with single line compact sexy comments
|
||||
|
||||
2.1.12
|
||||
- added support for patran and dakota, thx to Jacobo Diaz for the email
|
||||
|
||||
@@ -1284,12 +1284,14 @@ function s:CommentLinesSexy(topline, bottomline)
|
||||
call setline(a:topline, theLine)
|
||||
|
||||
"comment the bottom line
|
||||
if a:bottomline != a:topline
|
||||
let theLine = getline(a:bottomline)
|
||||
let lineHasTabs = s:HasLeadingTabs(theLine)
|
||||
if lineHasTabs
|
||||
let theLine = s:ConvertLeadingTabsToSpaces(theLine)
|
||||
endif
|
||||
let theLine = s:SwapOutterMultiPartDelimsForPlaceHolders(theLine)
|
||||
endif
|
||||
let theLine = s:AddRightDelim(spaceString . right, theLine)
|
||||
if lineHasTabs
|
||||
let theLine = s:ConvertLeadingSpacesToTabs(theLine)
|
||||
|
||||
Reference in New Issue
Block a user