Class Order Style

Lenny Lowood via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Tue Feb 21 14:41:40 PST 2017


On Monday, 20 February 2017 at 18:02:20 UTC, Jolly James wrote:
> On Monday, 20 February 2017 at 13:50:26 UTC, ketmar wrote:
>> just add ddoc documentation to 'em, and then it doesn't matter 
>> in which order they are declared: people will generate 
>> documentation to find out how to use your code. ;-)
>
> ah okay, thx
>
>
> But what about this?
>
>>>class A
>>>{
>>>private:
>>>    int a;
>>>    int b;
>>>public:
>>>    int c;
>>>    int d;
>>>}
>> or
>>>class A
>>>{
>>>    private
>>>    {
>>>        int a;
>>>        int b;
>>>    }
>>>    public
>>>    {
>>>        int c;
>>>        int d;
>>>    }
>>>}


Me as a beginner would like to know this, too ...


More information about the Digitalmars-d-learn mailing list