const, auto and struct/class methods

Joseph Rushton Wakeling joseph.wakeling at webdrake.net
Mon Nov 25 03:11:41 PST 2013


On 25/11/13 12:00, bearophile wrote:
> Is this acceptable?
>
> struct Foo {
>      auto bar() {
>          const result = ...;
>          return result;
>      }
> }

Could work, nice thought :-)  I was hoping for something in the function 
signature rather than internally, though.


More information about the Digitalmars-d-learn mailing list