Encouraging memory efficiency

Nick Treleaven via Digitalmars-d digitalmars-d at puremagic.com
Mon Jul 21 09:10:12 PDT 2014


On 19/07/2014 01:31, Timon Gehr wrote:
> auto createBuffer(T,alias size)(T[]
> buf=(cast(T*)alloca(size))[0..size]){ return buf; }

alloca(T.sizeof * size)


More information about the Digitalmars-d mailing list