7025468: Tests using diamond with anonymous inner classes needs to be reverted
Reviewed-by: dholmes, forax
This commit is contained in:
parent
1daa47b01d
commit
a36a5ce599
@ -69,7 +69,7 @@ public class Basic {
|
|||||||
throw new RuntimeException("entry not found");
|
throw new RuntimeException("entry not found");
|
||||||
|
|
||||||
// check filtering: f* should match foo
|
// check filtering: f* should match foo
|
||||||
DirectoryStream.Filter<Path> filter = new DirectoryStream.Filter<>() {
|
DirectoryStream.Filter<Path> filter = new DirectoryStream.Filter<Path>() {
|
||||||
private PathMatcher matcher =
|
private PathMatcher matcher =
|
||||||
dir.getFileSystem().getPathMatcher("glob:f*");
|
dir.getFileSystem().getPathMatcher("glob:f*");
|
||||||
public boolean accept(Path file) {
|
public boolean accept(Path file) {
|
||||||
|
@ -53,7 +53,7 @@ import java.util.concurrent.PriorityBlockingQueue;
|
|||||||
public class NoNulls {
|
public class NoNulls {
|
||||||
void test(String[] args) throws Throwable {
|
void test(String[] args) throws Throwable {
|
||||||
final Comparator<String> nullTolerantComparator
|
final Comparator<String> nullTolerantComparator
|
||||||
= new Comparator<>() {
|
= new Comparator<String>() {
|
||||||
public int compare(String x, String y) {
|
public int compare(String x, String y) {
|
||||||
return (x == null ? -1 :
|
return (x == null ? -1 :
|
||||||
y == null ? 1 :
|
y == null ? 1 :
|
||||||
@ -65,7 +65,7 @@ public class NoNulls {
|
|||||||
nullSortedSet.add(null);
|
nullSortedSet.add(null);
|
||||||
|
|
||||||
final PriorityQueue<String> nullPriorityQueue
|
final PriorityQueue<String> nullPriorityQueue
|
||||||
= new PriorityQueue<>() {
|
= new PriorityQueue<String>() {
|
||||||
public Object[] toArray() { return new Object[] { null };}};
|
public Object[] toArray() { return new Object[] { null };}};
|
||||||
|
|
||||||
final Collection<String> nullCollection = new ArrayList<>();
|
final Collection<String> nullCollection = new ArrayList<>();
|
||||||
|
Loading…
Reference in New Issue
Block a user