A few questions

Simen Kjaeraas simen.kjaras at gmail.com
Fri Jul 27 10:34:52 PDT 2012


On Fri, 27 Jul 2012 17:35:19 +0200, Jonathan M Davis <jmdavisProg at gmx.com>  
wrote:

> Many of us think that
>
> const Foo func() {}
>
> should just become illegal inconsistency or not because of all of this
> confusion, but Walter doesn't buy into that.

Like monarch_dodra said, this is also a style favored by some:

@pure @property const
int foo() {
     //...
}

Having to write that

@pure @property
int foo() const {
     //...
}

at the very least feels weird.

int foo()
const @pure @property {
}

could work, I guess. But it feels backward.

-- 
Simen


More information about the Digitalmars-d-learn mailing list