On Fri, 20 May 2011 21:44:19 +0300, Jonathan M Davis <[email protected]> wrote:

That wouldn't work with

A a(args, to, constructor);

Now, I personally never use that syntax and always use

auto a = A(args, to, constructor);

but you can't do the first form without a constructor, and even in the second form, you're making it clear that you're spefically constructing a value of that type as opposed to using a some random function which happens to produce that type. But ultimately, constructors are just special functions anyway.

- Jonathan M Davis

Wait a minute, i thought "A a(args, to, constructor)" wasn't allowed in D.
And "test t(5);" gives an error.

Reply via email to