nogc Array
Jonathan M Davis via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Mon Jan 25 20:40:16 PST 2016
On Tuesday, January 26, 2016 03:03:40 Igor via Digitalmars-d-learn wrote:
> Is there a GC-less array that we can use out of the box or do I
> have to create my own?
If what you want is a dynamic array (as opposed std.container.Array), then
you can simply malloc the memory and then slice it to get a dynamic array.
It's just that it's then up to you to manage the memory properly, and if you
attempt to append or concatenate, it'll result in the GC allocating a new
array.
- Jonathan M Davis
More information about the Digitalmars-d-learn
mailing list