immutable class can't override opEquals, workaround?

SimonN via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sun Feb 21 16:33:53 PST 2016


On Sunday, 21 February 2016 at 07:58:42 UTC, Jonathan M Davis 
wrote:
> opEquals still works with const and immutable
> if it's legal to use a class as the key in an AA, it's a bug

> have a working version of the PR
> hasn't even been looked at yet from what I can tell,
> and it's the simplest of the bits that need to be done

Thanks for the detailed overview.

Judging from the source comment at hack-casting const to mutable, 
naive improvements affect much more code than I have imagined.

The problem and possible solutions are on the radar still, that's 
satisfying. I understand if it takes more time, even if I too 
deem it important.

-- Simon


More information about the Digitalmars-d-learn mailing list