Feature request - simpler constructors
Matti Niemenmaa
see_signature at for.real.address
Thu Sep 20 08:27:27 PDT 2007
Bill Baxter wrote:
> I guess the main worry lurking in the back of my mind is that we may
> actually want to use auto in parameter lists someday to mean more or
> less what it means in declarations:
>
> void foo(auto y = "hi there",
> auto x = 23.f,
> const z = ABigNamedStruct())
> {. . . }
>
> And having it mean something slightly different for 'this' methods than
> for an ordinary 'foo' method would just be confusing.
The precise syntax isn't that important. It could just as well be either of the
following, for instance (using 'a' and 'b' as parameters which you don't want to
be automatically handled):
this(a, auto [x, y, z], b) {}
this(a, auto: (x, y, z), b) {}
--
E-mail address: matti.niemenmaa+news, domain is iki (DOT) fi
More information about the Digitalmars-d
mailing list