# | Line 39 | Line 39 | public class MapWordLoops { | |
---|---|---|
39 | ||
40 | for (int s = WORDS_FILES.length-1; s >= 0; --s) | |
41 | tests(mapClass, numTests, s); | |
42 | – | |
42 | } | |
43 | ||
44 | static void tests(Class<?> mapClass, int numTests, int sizeIndex) { | |
# | Line 67 | Line 66 | public class MapWordLoops { | |
66 | ||
67 | static Map<String,String> newMap(Class<?> cl) { | |
68 | try { | |
69 | < | Map m = (Map<String,String>)cl.newInstance(); |
71 | < | return m; |
69 | > | return (Map<String,String>) cl.getConstructor().newInstance(); |
70 | } catch (Exception e) { | |
71 | throw new RuntimeException("Can't instantiate " + cl + ": " + e); | |
72 | } |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |