read() performance - Linux.too?

Lionello Lunesu lio at lunesu.remove.com
Mon Jul 24 23:25:38 PDT 2006


Derek Parnell wrote:
 >.....
>     void *p = malloc(size);
>     if (p == null)
>         throw new OutOfMemoryException;
>     buf = cast(byte[])p[0..size];
> 
> I assume that the " = p[x..y]" construct adds the root to the GC.

I doubt that.

L.



More information about the Digitalmars-d mailing list