ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/test/jtreg/util/Collections/Disjoint.java
(Generate patch)

Comparing jsr166/src/test/jtreg/util/Collections/Disjoint.java (file contents):
Revision 1.5 by jsr166, Tue Sep 15 04:57:49 2015 UTC vs.
Revision 1.7 by jsr166, Sun Oct 22 02:59:18 2017 UTC

# Line 34 | Line 34 | import java.util.*;
34   public class Disjoint {
35      static final int N = 20;
36  
37 <    public static void main(String args[]) {
37 >    public static void main(String[] args) {
38          // Make an array of lists each of which shares a single element
39          // with its "neighbors," and no elements with other lists in the array
40          Random rnd = new Random();
# Line 42 | Line 42 | public class Disjoint {
42          int x = 0;
43          for (int i = 0; i < N; i++) {
44              int size = rnd.nextInt(10) + 2;
45 <            List<Integer> list = new ArrayList<Integer>(size);
45 >            List<Integer> list = new ArrayList<>(size);
46              for (int j = 1; j < size; j++)
47                  list.add(x++);
48              list.add(x);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines