D's "accessors" are like abusing operator overloads
Nick Sabalausky
a at a.a
Fri Mar 27 21:44:43 PDT 2009
"Derek Parnell" <derek at psych.ward> wrote in message
news:b3ttq8dh6euj.6tg6gfg6kfnj.dlg at 40tude.net...
> On Fri, 27 Mar 2009 18:57:50 +0300, Denis Koroskin wrote:
>
>> This way you can't do "a = b = c = 42;"-style chaining.
>
> A bit off topic, but what's so good about that coding style anyway?
>
I've been known to use it now and then if there's a few variables I'm
initing to the same value (assuming of course that the whole point is for
the variables to start out at the same value). It's certainly not a huge
improvement, but I see nothing wrong with it.
More information about the Digitalmars-d
mailing list