Re: Separate allocation and construction?

2014-06-05 Thread Adam D. Ruppe via Digitalmars-d-learn
On Thursday, 5 June 2014 at 22:22:16 UTC, Chris Williams wrote: If I wanted to allocate memory for a class and then call its constructor as two separate steps, while still having the object be managed by the garbage collector, is there any way to do that? Check out std.conv.emplace

Separate allocation and construction?

2014-06-05 Thread Chris Williams via Digitalmars-d-learn
If I wanted to allocate memory for a class and then call its constructor as two separate steps, while still having the object be managed by the garbage collector, is there any way to do that? I believe that I've figured out a way to accomplish the first step, but not the second. import

Re: Separate allocation and construction?

2014-06-05 Thread Chris Williams via Digitalmars-d-learn
On Thursday, 5 June 2014 at 22:25:03 UTC, Adam D. Ruppe wrote: On Thursday, 5 June 2014 at 22:22:16 UTC, Chris Williams wrote: If I wanted to allocate memory for a class and then call its constructor as two separate steps, while still having the object be managed by the garbage collector, is

Re: Separate allocation and construction?

2014-06-05 Thread Ali Çehreli via Digitalmars-d-learn
On 06/05/2014 03:47 PM, Chris Williams wrote: On Thursday, 5 June 2014 at 22:25:03 UTC, Adam D. Ruppe wrote: On Thursday, 5 June 2014 at 22:22:16 UTC, Chris Williams wrote: If I wanted to allocate memory for a class and then call its constructor as two separate steps, while still having the