-
Notifications
You must be signed in to change notification settings - Fork 21
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
Preservation of empty lines is broken #83
Comments
The issue is in the second clause of is_last_and_before_empty_line(H, [], #ctxt{empty_lines = EmptyLines}) ->
lists:member(get_pos(H) + 1, EmptyLines);
is_last_and_before_empty_line(H, [H2 | _], #ctxt{empty_lines = EmptyLines}) ->
get_pos(H2) - get_pos(H) >= 2 andalso lists:member(get_pos(H) + 1, EmptyLines).
|
This was not completely fixed, see https://github.com/AdRoll/erliam/pull/5/files#r409081479 |
* Add rebar3 formatting * Remove old way * Remove lint warnings * Actually verify the formatting on CI * Remove support for OTP 20 * Revert indentation of long lists * Moving comments until AdRoll/rebar3_format#83 is fixed
Actually… that thing is by design. The formatter does not preserve empty spacing between clauses. It doesn't preserve it between function clauses, case clauses, if clauses, etc… |
A file like this one…
…results in…
…while it should result in…
The text was updated successfully, but these errors were encountered: