Where to place function attributes?

Simen Kjaeraas simen.kjaras at gmail.com
Sun Aug 19 12:40:31 PDT 2012


On Sun, 19 Aug 2012 10:15:42 +0200, Jonathan M Davis <jmdavisProg at gmx.com>  
wrote:

>  it's generally considered good practice to put const and immutable on  
> the right-hand side.

I would also say that putting function attributes on a separate line
above the function is fairly common:

const @property pure
int foo() {
     return 3;
}

-- 
Simen


More information about the Digitalmars-d-learn mailing list