AA.remove in foreach && AA = new vs cleaning
Saaa
empty at needmail.com
Wed Oct 21 23:59:13 PDT 2009
Saaa wrote:
> Steven Schveighoffer wrote
>
>>> But I've changed everything to `new` the array afterwards as I deleted
>>> all the
>>> keys anyways.
>>
>> Not sure what you mean here.
>
> foreach (K k, ; aa)
> {
> ..
> //aa.remove(k);
> }
> aa = new int[char];
Error: new can only create structs, dynamic arrays or class objects
So, what is the fastest way to clean an AA?
More information about the Digitalmars-d-learn
mailing list