Allocate an Array!T on the heap?

2012-06-22 Thread Tobias Pankrath
import std.container; struct A {}; void main() { Array!(A)* arr = new Array!(A); } yields bug.d(7): Error: template std.container.Array!(A).Array.__ctor does not match any function template declaration /usr/include/d/std/container.d(1625): Error: template

Re: Allocate an Array!T on the heap?

2012-06-22 Thread Timon Gehr
On 06/22/2012 08:45 AM, Tobias Pankrath wrote: import std.container; struct A {}; void main() { Array!(A)* arr = new Array!(A); } yields bug.d(7): Error: template std.container.Array!(A).Array.__ctor does not match any function template declaration /usr/include/d/std/container.d(1625):

Re: Allocate an Array!T on the heap?

2012-06-22 Thread Tobias Pankrath
On Friday, 22 June 2012 at 10:19:13 UTC, Timon Gehr wrote: On 06/22/2012 08:45 AM, Tobias Pankrath wrote: import std.container; struct A {}; void main() { Array!(A)* arr = new Array!(A); } yields bug.d(7): Error: template std.container.Array!(A).Array.__ctor does not match any function