Return-Path: Delivered-To: apmail-incubator-harmony-commits-archive@www.apache.org Received: (qmail 13215 invoked from network); 24 Apr 2006 12:53:28 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 24 Apr 2006 12:53:28 -0000 Received: (qmail 79275 invoked by uid 500); 24 Apr 2006 12:53:16 -0000 Delivered-To: apmail-incubator-harmony-commits-archive@incubator.apache.org Received: (qmail 79239 invoked by uid 500); 24 Apr 2006 12:53:16 -0000 Mailing-List: contact harmony-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: harmony-dev@incubator.apache.org Delivered-To: mailing list harmony-commits@incubator.apache.org Received: (qmail 79228 invoked by uid 99); 24 Apr 2006 12:53:16 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 24 Apr 2006 05:53:16 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [209.237.227.198] (HELO brutus.apache.org) (209.237.227.198) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 24 Apr 2006 05:53:16 -0700 Received: from brutus (localhost.localdomain [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 8A7E3714293 for ; Mon, 24 Apr 2006 12:52:07 +0000 (GMT) Message-ID: <558479.1145883127564.JavaMail.jira@brutus> Date: Mon, 24 Apr 2006 12:52:07 +0000 (GMT+00:00) From: "Mark Hindess (JIRA)" To: harmony-commits@incubator.apache.org Subject: [jira] Updated: (HARMONY-403) HashMap hashcode ignores values in entries In-Reply-To: <27861878.1145882825682.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N [ http://issues.apache.org/jira/browse/HARMONY-403?page=all ] Mark Hindess updated HARMONY-403: --------------------------------- Attachment: hashmap.hashcodes.should.differ.diff (Oops, attached these in the wrong order but JIRA wont really show this so I should have kept quiet.) The file "fix.hashmap.hashcode.diff" is a fix that I thought might fix the problem but actually doesn't. However, it still "smells" like a bug to me. > HashMap hashcode ignores values in entries > ------------------------------------------ > > Key: HARMONY-403 > URL: http://issues.apache.org/jira/browse/HARMONY-403 > Project: Harmony > Type: Bug > Components: Classlib > Reporter: Mark Hindess > Priority: Minor > Attachments: fix.hashmap.hashcode.diff, hashmap.hashcodes.should.differ.diff > > While it is obviously trivial to create different HashMaps with identical hashCodes, I'd still expect the following test code to pass: > HashMap map1 = new HashMap(10); > HashMap map2 = new HashMap(10); > map1.put("key", "1"); > map2.put("key", "2"); > assertFalse(map1.hashCode() == map2.hashCode()); > That is, I'd expect the 'value' associated with "key" to have some impact on the hashCode. It passes on the reference implementations I tested. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira