You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Comments on the same line as a closing curly brace should be associated with the statement, much like comments on the same line as a semi-colon is captured in post_comments.
For example:
typeenumeration {
enum foo { value10; } // Comment associated with "foo"enum bar { value20; } // Comment associated with "bar"
}
Currently the comments are treated as their own nodes, which leads to this formatting:
typeenumeration {
enum foo {
value10;
}
// Comment associated with "foo"enum bar {
value20;
}
// Comment associated with "bar"
}
Instead, these comments should be captured into post_comments as well, resulting in the following formatting:
typeenumeration {
enum foo { // Comment associated with "foo"value10;
}
enum bar { // Comment associated with "bar"value20;
}
}
This means it's technically possible for the formatter to put two single-line comments on the same line, but that should never happen in practice.
The text was updated successfully, but these errors were encountered:
Comments on the same line as a closing curly brace should be associated with the statement, much like comments on the same line as a semi-colon is captured in
post_comments
.For example:
Currently the comments are treated as their own nodes, which leads to this formatting:
Instead, these comments should be captured into
post_comments
as well, resulting in the following formatting:This means it's technically possible for the formatter to put two single-line comments on the same line, but that should never happen in practice.
The text was updated successfully, but these errors were encountered: