-
Notifications
You must be signed in to change notification settings - Fork 503
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
Can't reformat correctly in a round with trailing_comma_on_call_site
enabled
#1642
Comments
trailing_comma_on_call_site
enabled
Yep. Noticed this too. For instance here: https://github.com/vanniktech/gradle-code-quality-tools-plugin/pull/245/files#diff-7885ec759a167c69428552655473fc77195bb3733559c7e27bb3b2d26d36452aL21 Note though that I'm stuck on the second loop and it won't do the third and place |
In the examples above, the trailing comma should not have been added. Currently it is added because the VALUE_ARGUMENT_LIST is a multiline statement and any newline inside the VALUE_ARGUMENT_LIST is considered to be a reason to add the trailing comma. |
…er is only found inside a multiline argument. Only in case a newline character is found between arguments, this should be taken into account to add a trailing comma. * Refactor and cleanup unused branches in isMultiline method Closes pinterest#1642
Expected Behavior
Reformat correctly in a round with
trailing_comma_on_call_site
enabled.Observed Behavior
Need to format correctly code below for 3 times.
Original:
Steps to Reproduce
First round reformat:
Second round reformat:
Third round:
You can start from the second step, also need 2 rounds to format.
Your Environment
.editorconfig
settings https://github.com/Goooler/DemoApp/blob/trunk/.editorconfigThe text was updated successfully, but these errors were encountered: