Issue 3789, stucts equality

Andrej Mitrovic andrej.mitrovich at gmail.com
Thu Mar 29 04:49:28 PDT 2012


On 3/27/12, Steven Schveighoffer <schveiguy at yahoo.com> wrote:
> That's exactly what bug 3789 advocates for.  Please vote up!
>
> http://d.puremagic.com/issues/show_bug.cgi?id=3789

Unrelated, but I don't understand bugzilla's stupid 10-vote
limitation. As if I can only care about 10 bugs. I agree with 3789, ==
should do the safe thing by default.

Speaking of which, does anyone have some sort of template to
autogenerate an opEquals that compares all fields of a struct via
'=='? I could write it (maybe via traits & getAllMembers) but surely
someone has done it before.


More information about the Digitalmars-d mailing list