[llvm-commits] CVS: llvm-java/test/Programs/SingleSource/UnitTests/Maps1.java Maps.java
Alkis Evlogimenos
alkis at cs.uiuc.edu
Wed Feb 2 10:54:58 PST 2005
Changes in directory llvm-java/test/Programs/SingleSource/UnitTests:
Maps1.java updated: 1.1 -> 1.2
Maps.java updated: 1.2 -> 1.3
---
Log message:
Use code from Maps
---
Diffs of the changes: (+7 -8)
Maps.java | 6 +++---
Maps1.java | 9 ++++-----
2 files changed, 7 insertions(+), 8 deletions(-)
Index: llvm-java/test/Programs/SingleSource/UnitTests/Maps1.java
diff -u llvm-java/test/Programs/SingleSource/UnitTests/Maps1.java:1.1 llvm-java/test/Programs/SingleSource/UnitTests/Maps1.java:1.2
--- llvm-java/test/Programs/SingleSource/UnitTests/Maps1.java:1.1 Tue Jan 25 16:31:40 2005
+++ llvm-java/test/Programs/SingleSource/UnitTests/Maps1.java Wed Feb 2 12:54:47 2005
@@ -5,10 +5,9 @@
public static Random rand = new Random(0);
public static void main(String[] args) {
- HashMap tmap = new HashMap();
- for (int i = 0; i < 1000; ++i)
- tmap.put(new Integer(i), new Integer(rand.nextInt()));
- for (int i = 0; i < 1000; ++i)
- Test.println(((Integer)tmap.get(new Integer(i))).intValue());
+ HashMap map = new HashMap();
+ fillMapWithRandomInts(map);
+ printIntMap(map);
+ }
}
}
Index: llvm-java/test/Programs/SingleSource/UnitTests/Maps.java
diff -u llvm-java/test/Programs/SingleSource/UnitTests/Maps.java:1.2 llvm-java/test/Programs/SingleSource/UnitTests/Maps.java:1.3
--- llvm-java/test/Programs/SingleSource/UnitTests/Maps.java:1.2 Wed Feb 2 12:53:21 2005
+++ llvm-java/test/Programs/SingleSource/UnitTests/Maps.java Wed Feb 2 12:54:47 2005
@@ -18,8 +18,8 @@
}
public static void main(String[] args) {
- TreeMap tmap = new TreeMap();
- fillMapWithRandomInts(tmap);
- printIntMap(tmap);
+ TreeMap map = new TreeMap();
+ fillMapWithRandomInts(map);
+ printIntMap(map);
}
}
More information about the llvm-commits
mailing list