mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-21 13:20:56 +07:00
15 lines
363 B
Java
15 lines
363 B
Java
// "Fuse newHashSet into the Stream API chain" "true-preview"
|
|
package com.google.common.collect;
|
|
|
|
import java.util.*;
|
|
import java.util.stream.*;
|
|
|
|
class X {
|
|
void foo(Stream<String> s) {
|
|
Set<String> set = Sets.newHashSet(s.co<caret>llect(Collectors.toSet()));
|
|
}
|
|
}
|
|
|
|
class Sets {
|
|
public static native <E> HashSet<E> newHashSet(Iterable<? extends E> var0);
|
|
} |