2004-05-05 Mark Wielaard <mark@klomp.org>
Reported by f.haeglsperger@gmx.de [classpath patch #2485]
* java/util/HashMap.java (rehash): Add entry at start of bucket.
From-SVN: r81512
+2004-05-05 Mark Wielaard <mark@klomp.org>
+
+ Reported by f.haeglsperger@gmx.de [classpath patch #2485]
+ * java/util/HashMap.java (rehash): Add entry at start of bucket.
+
2004-05-05 Tom Tromey <tromey@redhat.com>
* java/io/BufferedReader.java (skip): Removed unused
{
int idx = hash(e.key);
HashEntry dest = buckets[idx];
-
- if (dest != null)
- {
- while (dest.next != null)
- dest = dest.next;
- dest.next = e;
- }
- else
- buckets[idx] = e;
-
HashEntry next = e.next;
- e.next = null;
+ e.next = buckets[idx];
+ buckets[idx] = e;
e = next;
}
}