byKey and byValue: properties or methods?
bearophile
bearophileHUGS at lycos.com
Tue Jan 17 14:51:24 PST 2012
Alvaro:
> So, not bad. In those [infrequent, I'd say] cases needing an array one
> would do:
>
> auto keys = array(aa.keys);
Unfortunately in D you often need arrays, so those cases are frequent.
> even: (unsure if this would work, but somethig similar maybe)
>
> foreach(k; array(aa.keys).sort)
> {
> ... use the ordered keys
> }
sort property is deprecated (or going to be).
Bye,
bearophile
More information about the Digitalmars-d
mailing list