Enable auto-close of multi-line comments in cpp#160357
Merged
aeschli merged 2 commits intomicrosoft:mainfrom Sep 26, 2022
Merged
Enable auto-close of multi-line comments in cpp#160357aeschli merged 2 commits intomicrosoft:mainfrom
aeschli merged 2 commits intomicrosoft:mainfrom
Conversation
Contributor
|
#77008 has led to the removal of I personally agree that we should add them back as IMO the benefits outweigh the drawback. The main benefit s that this avoids to comment out the full file, causing folding ranges, outline, syntax highlighting flickering. @alexr00 Any objections? |
Member
|
No objections. |
alexr00
approved these changes
Sep 8, 2022
sean-mcmanus
added a commit
to sean-mcmanus/vscode
that referenced
this pull request
Oct 10, 2022
1. View->Toggle Developer Console shows Bug: Errors parsing ...AppData/Local/Programs/Microsoft%20VS%20Code%20Insiders/resources/app/extensions/cpp/language-configuration.json: [379, 1] Comma expected _readConfigFile @ workbench.desktop.main.js:2140 NOTE: Follow up to microsoft#160357
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related to: #154994
Ideally, we'd also like to be able to enable/disable auto-closing of comments separately from brackets ( #154994 ). That also could soften the impact of this change on existing cpp users.
It's unclear to me why TypeScript uses
/**and*/. In this case, for C++, we'd like to use/*and*/to match the behavior of VS.One of the motivations for this change is to enable automatic insertion of doxygen comments (a feature in cpptools), when using a multi-line comment style for them. As currently implemented, this fails as it implicitly turn the rest of the file into a comment before the correct doxygen contents can be determined. This solution, of allowing the auto-closing to occur first, is the same solution used by VS.