Steven Schveighoffer Wrote: > > There is specific code in array appending that locks a global lock when > appending to shared arrays. Appending to __gshared arrays from multiple > threads likely will not work in some cases though. I don't know how to > get around this, since the runtime is not made aware that the data is > shared.
The shared attribute will have to become a part of the TypeInfo, much like const is now. Knowing whether data is shared can affect where/how the memory block is allocated by the GC, etc.