-
-
Notifications
You must be signed in to change notification settings - Fork 190
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
Oscillating newlines in custom computation expression #1463
Comments
Hello Theodor, thank you for taking the time to report this issue. To solve this you will need to add fantomas/src/Fantomas/CodePrinter.fs Lines 2642 to 2676 in 3304470
Are you interested in submitting a PR? If so, please read our Contribution Guidelines and add your test to |
Thanks for replying :) I will look into creating a pr this evening! |
Wonderful! Thanks for taking the time. If you have any question along the way, feel free to ask! |
Not sure what went wrong, but I checked fantomas-tools again, and it seemed to exhibit the same behavior as before the fix. It is using the latest commit from master. Do you know what went wrong here? It is not showing the same behavior that the tests do. |
Hmm, not sure what happened there. |
Ok! Thanks for getting back to me. Let me know if there is something more for me to do :) |
I redeployed again via an empty commit, the problem seems resolved now. Can you confirm? |
Yep, works on my end! Great :) |
Issue created from fantomas-online
Code
Result
Problem description
Fantomas adds a newline here, which by itself I don't mind. But when fantomas is run again on the newly outputted code, it reverts back to the first example. This goes back and forth every time fantomas runs, which makes for an unstable experience. Also it seems for format things correctly inside the
aggregateResult
, apart from the oscillating newlines. This issue does seem similar to #1227 though?Extra information
Options
Fantomas Master at 02/19/2021 13:56:09 - 3304470
Default Fantomas configuration
Did you know that you can ignore files when formatting from fantomas-tool or the FAKE targets by using a .fantomasignore file?
The text was updated successfully, but these errors were encountered: