[Issue 8435] BigInts don't work well in associative arrays

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Jul 7 20:44:36 PDT 2013


http://d.puremagic.com/issues/show_bug.cgi?id=8435



--- Comment #3 from hsteoh at quickfur.ath.cx 2013-07-07 20:44:34 PDT ---
This bug is caused by two problems:

1) BigInt does not define toHash(), so two different instances of BigInt will
always have a distinct hash, even if the values they represent are equal.

2) For some reason, typeid(BigInt).compare() will always return non-zero for
two distinct instances of BigInt; this causes the AA code to think the two
BigInts are not equal even if their hash is the same.

I have the fix for (1), but still investigating (2); it may be a compiler bug,
I'm not sure yet.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list