why are opCmp and opEquals not pure.
Stefan Koch via Digitalmars-d
digitalmars-d at puremagic.com
Thu Sep 17 11:37:04 PDT 2015
Hi,
is there any reason why opCmp and opEquals are not pure ?
I would argue it is very counter-intuitive to mutate any state
when comparing objects.
opCmp and opEquals not being annotated pure is a major problem
for me in writing ctfe-able code.
since any call to Object.opEquals need to be warped in another
function to be able to cast the Function pure.
More information about the Digitalmars-d
mailing list