-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[CLOSED] If first line in selection is a line comment, Block Comment does nothing #2044
Comments
Comment by peterflynn I think Block Comment may be trying to be overly clever with line comments. For example, if I select a single line-comment, Block Comment actually uncomments it (it does the same thing as Line Uncomment). If I select two consecutive line comments (and nothing else), then Block Comment no-ops. Or the above case: if I select a bunch of uncommented code that includes line-comments, depending on what the first line is Block Comment will either no-op or wrap in a block comment. It seems like the command might be more predictable, and the implementation simpler, if Block Comment just totally ignores the presence of line comments... |
Comment by TomMalbran I knew i was missing some cases on the implementation. I'll try to fix those. I do like the idea of having block-comment to uncomment line comments, is actually how Sublime Text 2 does it. Even removing this, it might still not make it that easier, since the Tokenizer only gives information about a comment and not if it is a line or a block-comment, so then we need to know in a line comment if we are inside a block comment or nor in some way, which is how it does it now. What I think is missing is having the line-comment uncomment a block-comment, so that it works similar to block-comment. |
Comment by pthiess Reviewed, assigned to |
Comment by peterflynn Nominating for Sprint 18 |
Comment by redmunds I guess this never got marked as Fix in Progress. Oh, well, FBNC back to |
Comment by peterflynn I can confirm this one is fixed now. Note that there are still a few inconsistencies remaining in block comment behavior, tracked in #2337. |
Issue by peterflynn
Thursday Nov 15, 2012 at 01:47 GMT
Originally opened as adobe/brackets#2118
Result: nothing happens
Expected: code is wrapped in a block comment
This also happens if the first line(s) are whitespace -- as long as the first non-whitespace line is a line comment, Block Comment won't do anything.
The text was updated successfully, but these errors were encountered: