December 02, 2005
"Stewart Gordon" <smjg_1998@yahoo.com> wrote in message news:dmfc73$2hec$1@digitaldaemon.com...
> But I'm guessing the problem to which you refer is that the beginning of such a slice might be the beginning of another array altogether, and so later changing its .length can overwrite the contents of the other array.  Can this actually happen with the current DMD/GDC?  Or does the structure of the GC heap somehow prevent it?

You're right that this can be a problem. The solution currently used is to allocate a bit more than necessary for the array, so an end slice will not be at the beginning of some other array later in memory.


1 2
Next ›   Last »