marijnh/CodeMirror — pull request #2631 by mtaran-google (2014-06-12 02:12:30+00:00)
Title: [comment addon] Avoid killing block comments outside selection

Currently, if you perform the uncomment command with the cursor outside a single-line block comment, it will uncomment that block comment. This is unfortunate behavior for cases where the block comment is used to describe the parameter to a function like `foo(/* index */ 0)`. It's also inconsistent: if you have a selection and a single-line block comment after the end of the selection, uncomment() will do nothing, however if you have a selection with a single-line block comment *before* the selection, it will line-comment out all the lines of the selection instead.

This also isn't a complete fix. For example if you have `/* foo */ bar /* baz */`, uncomment() still does the wrong thing when the cursor is on foo or baz.