CommentTracker#replaceAndRestoreComments: try to keep comments after the statement (not move them to the front)

This commit is contained in:
Tagir Valeev
2018-10-08 14:09:24 +07:00
parent bb5f074e2c
commit c09250da45
21 changed files with 59 additions and 43 deletions
@@ -5,10 +5,9 @@ import java.util.Collection;
public class Test {
void test(int[] arr) {
// comment
Arrays.stream(arr).forEach(x -> {
int y = x * 2;
if (x > y) return;
if (x > y) return; // comment
System.out.println(x);
});
}