<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Wed, Aug 17, 2016 at 3:04 AM, Maciej Izak <span dir="ltr"><<a href="mailto:hnb.code@gmail.com" target="_blank">hnb.code@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">2016-08-17 7:05 GMT+02:00 silvioprog <span dir="ltr"><<a href="mailto:silvioprog@gmail.com" target="_blank">silvioprog@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>Just try it:</div><div></div></blockquote></div><br>related to </div><div class="gmail_extra"><br></div><div class="gmail_extra"><a href="http://bugs.freepascal.org/view.php?id=28911" target="_blank">http://bugs.freepascal.org/vie<wbr>w.php?id=28911</a></div><div class="gmail_extra"><br></div><div class="gmail_extra">Sven comment: "I won't change the current implementation for now, because once I'm going to fix this I'm going to fix this correctly for all cases, including packages, everything else is merely a workaround. But for that I first need to finish my work on packages."</div><div class="gmail_extra"><br clear="all"><div>btw, already reported: <a href="http://bugs.freepascal.org/view.php?id=30433" target="_blank">http://bugs.freepasc<wbr>al.org/view.php?id=30433</a></div></div></div></blockquote></div><div class="gmail_extra"><br></div><div class="gmail_extra">Indeed. After some debug I found where the exception is raised:</div><div class="gmail_extra"><br></div><div class="gmail_extra">...</div><div class="gmail_extra"><div class="gmail_extra">function TOpenAddressingLP<OPEN_<wbr>ADDRESSING_CONSTRAINTS>.<wbr>FindBucketIndex(constref AItems: TArray<TItem>;</div><div class="gmail_extra"> constref AKey: TKey; out AHash: UInt32): SizeInt;</div><div class="gmail_extra">var</div><div class="gmail_extra"> LItem: {TOpenAddressing<OPEN_<wbr>ADDRESSING_CONSTRAINTS>.}_<wbr>TItem; // for workaround Lazarus bug #25613</div><div class="gmail_extra"> LLengthMask: SizeInt;</div><div class="gmail_extra"> i, m: SizeInt;</div><div class="gmail_extra"> LHash: UInt32;</div><div class="gmail_extra">begin</div><div class="gmail_extra"> m := Length(AItems);</div><div class="gmail_extra"> LLengthMask := m - 1;</div><div class="gmail_extra"><br></div><div class="gmail_extra"> LHash := FEqualityComparer.GetHashCode(<wbr>AKey); // << here</div><div class="gmail_extra">...</div></div><div class="gmail_extra"><br></div><div class="gmail_extra">but I can't step into FEqualityComparer.GetHashCode to check why it happens, so I'll wait for Sven too. ^^</div><div class="gmail_extra"><br></div><div class="gmail_extra">I need to find the values using case-insensitive keys (I'm using it in a class registry of my app), so unfortunately this bug doesn't let me to use TDictionary on FPC yet. :-(</div><div class="gmail_extra"><br></div>--<br><div data-smartmail="gmail_signature"><div dir="ltr"><div>Silvio Clécio</div></div></div>
</div></div>