Skip to content
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

Fix formatter on call without parentheses followed by doc comment #14354

Conversation

straight-shoota
Copy link
Member

@straight-shoota straight-shoota commented Mar 8, 2024

This skip_space would consume trailing comments, newlines and comments after newlines which on calls without parentheses. It would be fine to keep it when there are parentheses (because then we expect OP_RPAREN), but it seems to be entirely unnecessary.

Resolves #14286

This `skip_space` would consume trailing comments, newlines and comments
after newlines which on calls without parentheses.
It would be fine to keep it when there are parentheses (because then we
expect `OP_RPAREN`), but it seems to be entirely unnecessary.
@straight-shoota straight-shoota force-pushed the fix/formatter-trailing-comment-doc-comment branch from 11c2d2f to e4547ca Compare March 8, 2024 09:56
@straight-shoota straight-shoota changed the title Remove skip_space at end of Call Fix formatter on call without parenthesis followed by doc comment Mar 8, 2024
@straight-shoota straight-shoota changed the title Fix formatter on call without parenthesis followed by doc comment Fix formatter on call without parentheses followed by doc comment Mar 8, 2024
@straight-shoota straight-shoota added this to the 1.12.0 milestone Mar 8, 2024
@straight-shoota straight-shoota merged commit 15c66d0 into crystal-lang:master Mar 10, 2024
58 checks passed
@straight-shoota straight-shoota deleted the fix/formatter-trailing-comment-doc-comment branch March 10, 2024 12:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unwanted line break added by the formatter
2 participants