D array expansion and non-deterministic re-allocation

Walter Bright newshound1 at digitalmars.com
Mon Nov 16 00:36:05 PST 2009


grauzone wrote:
> Even if it's memory safe, it could cause a bug. Look at Bartosz example 
> again; if the memory block gets copied really depends from the input 
> data length.

Yes, it could cause a bug. But it isn't undefined-behavior, it isn't 
memory corruption, and it isn't non-deterministic.

     i = ++i;

can also cause a bug.



More information about the Digitalmars-d mailing list