std.collection - changing the collection while iterating

Andrei Alexandrescu via Digitalmars-d digitalmars-d at puremagic.com
Sun Jun 21 17:36:20 PDT 2015


On 6/21/15 4:55 PM, H. S. Teoh via Digitalmars-d wrote:
>> >1. Leave it undefined, like the STL does. Probably this is too
>> >extreme.
> It may be extreme, but it also seems sanest, since it avoids treading in
> the dangerous territory of strange and counterintuitive behaviours when
> a container is modified in the middle of an iteration.

One important pursuit about std.collection is they're safe. -- Andrei




More information about the Digitalmars-d mailing list