On Wed, 1 Dec 2010 03:17:24 -0800 Jonathan M Davis <[email protected]> wrote:
> Various syntaxes have been proposed in the past. Syntax isn't really the > issue. > It's pretty easy to come up with one. I think that out of the ones I've seen, > the I liked the best was the one proposed by Michel Fortin: > > >I proposed the following a while ago. First allow the class reference > > > > to (optionally) be made explicit: > > C a; // mutable reference to mutable class > > C ref b; // mutable reference to mutable class > > > > And now you can apply tail-const to it: > > const(C)ref c; // mutable reference to const class > > const(C ref) d; // const reference to const class > > const(C) e; // const reference to const class This is the nicest proposal, imo as well. Is "ref" used here only because "C * b" would mean double indirection? Denis -- -- -- -- -- -- -- vit esse estrany ☣ spir.wikidot.com
