https://issues.dlang.org/show_bug.cgi?id=21550
Steven Schveighoffer <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #2 from Steven Schveighoffer <[email protected]> --- To clarify, a new array will be pointing at the front of the block unless the array size is large enough to be in an extendable block. Last I checked, that was 2k bytes. The reason is simple: array size is stored at the end of small blocks for alignment. But an extendable block can have the block size change from one call to the next. To avoid issues with that happening, the array size is stored at the front of the block, pushing the array off by some number of bytes. This leads to arr.ptr not pointing at the front of the block. The fix is also simple -- use the info.base just like the original. --
