std.file.dirEntries unsorted
Jonathan M Davis
jmdavisProg at gmx.com
Tue Dec 10 22:33:07 PST 2013
On Tuesday, December 10, 2013 18:11:07 Timothee Cour wrote:
> dirEntries depends on readdir, which has undefined order (eg:
> http://stackoverflow.com/questions/8977441/does-readdir-guarantee-an-order,
> and I've experienced as well dirEntries in non-alphabetical order)
>
> shouldn't we make dirEntries return in alphabetical order by default, with
> an option to return in unspecified native order for efficiency?
>
> at least, it should be specified in doc that order is undefined.
I don't know why you would ever have expected the order to be defined -
certainly trying to return them in alphabetical order would be quite inefficient
- but if you think that the docs should say so, then you can always open a
pull request.
- Jonathan M Davis
More information about the Digitalmars-d-learn
mailing list