StreamToLoopInspection: preserve comments; CommentTracker: now possible to delete element first and only after that register unchanged parts.

This commit is contained in:
Tagir Valeev
2016-12-23 18:00:01 +07:00
parent cd45987619
commit c9c574e428
20 changed files with 131 additions and 112 deletions

View File

@@ -5,7 +5,8 @@ import java.util.function.LongSupplier;
public class Main {
private static void test(List<String> list) {
long count = list.stream().filter(s -> !s.isEmpty()).co<caret>unt();
long count = list.stream(). // and filter!
filter(s -> !s/* comment */.isEmpty()).co<caret>unt();
if(count > 10) {
LongSupplier sup = () -> count*2;
long result = sup.get();