On Wednesday 25 August 2010 22:31:38 Yao G. wrote: > Sorry, I sent the message prematurely :( Anyway, here's complete: > > Is there a way to make compound assignment operators (-=, +=, *= and > friends) work with D's operator overload regime? I can't make them work.
Look at http://www.digitalmars.com/d/2.0/operatoroverloading.html (or even better, TDPL). The correct function would be opOpAssign. I believe that the syntax for += would be opOpAssign!("+")(args) { } - Jonathan M Davis
