8030244: Update langtools to use Diamond

Reviewed-by: darcy
This commit is contained in:
Brian Goetz 2013-12-18 16:05:18 -05:00
parent 6255412f38
commit 6b6b488756
216 changed files with 1006 additions and 1096 deletions

View file

@ -97,18 +97,19 @@ public class CleanProperties implements Transformer
}
// Sort the properties in increasing key order.
List<String> sortedKeys = new ArrayList<String>();
List<String> sortedKeys = new ArrayList<>();
for (Object key : p.keySet()) {
sortedKeys.add((String)key);
}
Collections.sort(sortedKeys);
Iterator<String> keys = sortedKeys.iterator();
// Collect the properties into a string buffer.
StringBuilder data = new StringBuilder();
while (keys.hasNext()) {
String key = keys.next();
data.append(CompileProperties.escape(key)+":"+CompileProperties.escape((String)p.get(key))+"\n");
for (String key : sortedKeys) {
data.append(CompileProperties.escape(key))
.append(":")
.append(CompileProperties.escape((String) p.get(key)))
.append("\n");
}
String destFilename = destRoot.getPath()+File.separator+pkgNameF+File.separator+src.getName();
@ -124,7 +125,7 @@ public class CleanProperties implements Transformer
Set<URI> as = packageArtifacts.get(pkgName);
if (as == null) {
as = new HashSet<URI>();
as = new HashSet<>();
packageArtifacts.put(pkgName, as);
}
as.add(dest.toURI());