[Issue 8250] dirEntries fails to generate file list when compiled with -inline

d-bugmail at puremagic.com d-bugmail at puremagic.com
Thu Oct 25 04:36:23 PDT 2012


http://d.puremagic.com/issues/show_bug.cgi?id=8250



--- Comment #2 from Joseph Rushton Wakeling <joseph.wakeling at webdrake.net> 2012-10-25 04:36:21 PDT ---
Sorry, the error in the above example is from inappropriate use of takeExactly.
:-(  dirEntries does indeed return an empty list, and when the correct subdir
is put in place, it returns the list of files.  So, it's not a minimal example
of the bug or even related.

However, I _am_ still experiencing this problem of an empty list due to a
filter which _should_ return a non-empty list of files, and indeed does when
compiled with ldmd2 -- but fails when compiled with latest from-GitHub dmd:

    auto fileList = dirEntries(testSetDir, "*.txt", SpanMode.shallow);
    foreach(DirEntry e; fileList)
    {
        ...
    }

If I remove the "*.txt" filter (there are only .txt files in the directory) the
fileList is correctly populated.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list