[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Field position attribute handling
From: |
Chris Gray |
Subject: |
Re: [PATCH] Field position attribute handling |
Date: |
Wed, 19 Nov 2003 22:12:17 +0100 |
On Wednesday 19 November 2003 11:38, Dalibor Topic wrote:
> Jeroen Frijters wrote:
> > Dalibor Topic wrote:
[...]
> >>If two objects are not equal, they should have different hashCodes.
> >
> > No this isn't true, however, if two objects are equal, they must have
> > identical hashCodes. It would be nice if unequal objects had different
> > hashCodes, but this is not a requirement.
>
> Note that I used *should* in my sentence instead of *must*, and reparse
> what I said ;)
In general it's impossible to ensure that non-equal objects have different
hashcodes - just think for a moment about java.lang.Long. So IMHO even
"should" is going too far ...
--
Chris Gray /k/ Embedded Java Solutions
Embedded & Mobile Java, OSGi http://www.kiffer.be/k/
address@hidden +32 477 599 703
- 3d attempt at Re: The right way(tm) of writing toString() (Was: Re: [PATCH] Field position attribute handling), (continued)
- 3d attempt at Re: The right way(tm) of writing toString() (Was: Re: [PATCH] Field position attribute handling), Dalibor Topic, 2003/11/30
- Re: [PATCH] Field position attribute handling, Tom Tromey, 2003/11/18
- Re: [PATCH] Field position attribute handling, Dalibor Topic, 2003/11/18
- Re: [PATCH] Field position attribute handling, Dalibor Topic, 2003/11/19
- Re: [PATCH] Field position attribute handling, Tom Tromey, 2003/11/19
- Re: [PATCH] Field position attribute handling, Dalibor Topic, 2003/11/19
- Re: [PATCH] Field position attribute handling, Tom Tromey, 2003/11/19
- Re: [PATCH] Field position attribute handling, Dalibor Topic, 2003/11/19
RE: [PATCH] Field position attribute handling, Jeroen Frijters, 2003/11/19