Optimize creation of boxed primitives

This commit is contained in:
Federico Bond
2014-08-25 03:50:14 -03:00
parent 25ed6fed3b
commit 80f64013a4
13 changed files with 35 additions and 35 deletions

View File

@@ -279,7 +279,7 @@ public class StringDict {
keys = PApplet.expand(keys);
values = PApplet.expand(values);
}
indices.put(key, new Integer(count));
indices.put(key, Integer.valueOf(count));
keys[count] = key;
values[count] = value;
count++;
@@ -325,8 +325,8 @@ public class StringDict {
keys[b] = tkey;
values[b] = tvalue;
indices.put(keys[a], new Integer(a));
indices.put(keys[b], new Integer(b));
indices.put(keys[a], Integer.valueOf(a));
indices.put(keys[b], Integer.valueOf(b));
}