Getting module of a class

Don nospam at nospam.com.au
Fri Oct 17 07:47:58 PDT 2008


Gregor Richards wrote:
> Jarrett Billingsley wrote:
>> On Fri, Oct 17, 2008 at 8:31 AM, Bill Baxter <wbaxter at gmail.com> wrote:
>>
>>> The reason is this:  these days it's en vogue to make classes contain
>>> as few functions as necessary, and to write everything else as
>>> non-member functions.
>>
>> OT: is it?  What's this "model" called?  "Oh, C was right after all"?  ;)
>>
>> What are the supposed advantages of developing like this?
> 
> Sounds like a poor impersonation of aspect-oriented programming, maybe 
> the idea is to make memberish functions not actually be members so that 
> other imports can write memberish functions that are as "1st-class". 
> Sort of ridiculous though.
> 
>  - Gregor Richards

No. The goal is to provide better encapsulation.
There's a paper by Scott Meyers about it.



More information about the Digitalmars-d mailing list