Files
Tagir Valeev dd689d3a39 [java-inspections] More tests for preview
GitOrigin-RevId: 6b6405ee4491ad1d58947547c40df6fb2d291ab7
2022-07-29 17:54:59 +00:00

13 lines
331 B
Java

// "Extract variable 'fn' to 'map' operation" "true-preview"
import java.util.*;
import java.util.function.*;
import java.util.stream.*;
public class Test {
void testFunction() {
Stream.of("a", "b", "c").map(x -> {
Supplier<String> <caret>fn = x::trim;
return fn.get();
}).forEach(System.out::println);
}
}