Re: Non-Deterministic / Unpredictable Behavior (Again) [SOLVED]

Ken Gentle <[email protected]> Sat, 12 Apr 2008 01:37:08 -0400
Newsgroups gmane.comp.windows.devel.java.advanced
Message-ID <[email protected]>
At the risk of making clear why I lurk more than participate, why did not
overriding hashcode in this instance (where the default equals is used)
introduce non-deterministic behavior?

Congrats on finding the issue - these types of problems are particularly
satisfying to solve, aren't they?

Ken

On Fri, Apr 11, 2008 at 10:38 AM, Randall R Schulz <[email protected]>
wrote:

> On Thursday 10 April 2008 18:25, Randall R Schulz wrote:
> > Hi,
> >
> > Well, I've done the fine-tooth-comb routine and still have the
> > problem of unrepeatable results.
> >
> > ...
>
> Well, I finally found the problem.
>
> The reason it escaped my attention was that I had an auxiliary class
> used internally in a key indexing structure that (intentionally) used
> identity equality semantics. Because I was using the default equals(),
> I did not implement a hashCode() override.
>
> Big mistake.
>
> Oh, well, I cleaned up a lot of other stuff along the way.
>
>
> Randall Schulz
>
> ===================================
> This list is hosted by DevelopMentor(R)  http://www.develop.com
>
> View archives and manage your subscription(s) at
> http://discuss.develop.com
>



--
J. Kenneth Gentle (Ken)
Gentle Software LLC
Phone: 484.371.8137
Mobile: 302.547.7151
Email: [email protected]
Email: [email protected]
www.gentlesoftware.com

===================================
This list is hosted by DevelopMentor®  http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com