Skip to content

Conversation

@clementdessoude
Copy link
Contributor

@clementdessoude clementdessoude commented Jan 3, 2020

What changed with this PR:

Fix line breaks in class bodies with empty statements. The calculation of separators between class member declarations was not taking account correctly of empty statements.

Example

// Input
public class Test {
  public TestField testField;;

  @Override
  public void someMethod() {}
}
// Output (v0.6.0)
public class Test {
  public TestField testField;
  @Override
  public void someMethod() {}
}

// Output after PR:
public class Test {
  public TestField testField;

  @Override
  public void someMethod() {}
}

Relative issues or prs:

Fix #356

@clementdessoude clementdessoude force-pushed the fix/blank-lines-empty-statements branch from 4f58120 to 2f990a2 Compare January 3, 2020 22:22
@clementdessoude clementdessoude marked this pull request as ready for review January 3, 2020 22:22
@clementdessoude clementdessoude changed the title Fix/blank lines empty statements fix: blank lines with empty statements Jan 3, 2020
@clementdessoude clementdessoude merged commit 28d03bb into jhipster:master Jan 3, 2020
@clementdessoude clementdessoude deleted the fix/blank-lines-empty-statements branch January 3, 2020 22:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Formatting not idempotent with duplicate semicolons

1 participant