--- a/jdk/src/share/classes/java/util/IdentityHashMap.java Mon Mar 10 14:32:51 2008 -0700
+++ b/jdk/src/share/classes/java/util/IdentityHashMap.java Mon Mar 10 15:07:09 2008 -0700
@@ -701,7 +701,7 @@
try {
IdentityHashMap<K,V> m = (IdentityHashMap<K,V>) super.clone();
m.entrySet = null;
- m.table = (Object[])table.clone();
+ m.table = table.clone();
return m;
} catch (CloneNotSupportedException e) {
throw new InternalError();
@@ -975,7 +975,7 @@
*/
public boolean removeAll(Collection<?> c) {
boolean modified = false;
- for (Iterator i = iterator(); i.hasNext(); ) {
+ for (Iterator<K> i = iterator(); i.hasNext(); ) {
if (c.contains(i.next())) {
i.remove();
modified = true;
@@ -1033,7 +1033,7 @@
return containsValue(o);
}
public boolean remove(Object o) {
- for (Iterator i = iterator(); i.hasNext(); ) {
+ for (Iterator<V> i = iterator(); i.hasNext(); ) {
if (i.next() == o) {
i.remove();
return true;
@@ -1121,7 +1121,7 @@
*/
public boolean removeAll(Collection<?> c) {
boolean modified = false;
- for (Iterator i = iterator(); i.hasNext(); ) {
+ for (Iterator<Map.Entry<K,V>> i = iterator(); i.hasNext(); ) {
if (c.contains(i.next())) {
i.remove();
modified = true;