[Issue 2657] Remove opPostInc, opPostDec

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Feb 16 03:36:34 PST 2009


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





------- Comment #3 from clugdbug at yahoo.com.au  2009-02-16 05:36 -------
Steven - I agree, it should be opInc. The opAddAssign(1) design assumes that
x+=int is valid, and that's not necessarily true. It plays havoc with templated
operators, too.

BCS - I'm not sure that that would work without guaranteed value copy
semantics. (This is part of the reason why postinc is such a pain).
Perhaps that can be done now with D2 copy constructors.
The question is, do we really need this functionality anyway?
Sure, C++ has it. But C++ has a lot of useless stuff.


-- 



More information about the Digitalmars-d-bugs mailing list