[beginner] Why nothing is printed to stdout ?
simendsjo
simendsjo at gmail.com
Sun Oct 30 04:17:24 PDT 2011
On 30.10.2011 11:00, Frédéric Galusik wrote:
> Hi,
>
> Can someone give me a clue on why nothing is printed to stdout ?
>
> I wish a list of files with their size.
>
> code:
> //
> import std.stdio;
> import std.file;
>
> void main(string[] args)
> {
> foreach (DirEntry e; dirEntries(".", SpanMode.shallow))
> {
> writeln(e.name, "\t", e.size);
> }
> }
> //
> Build with (dmd2):
> dmd -w test.d
>
Works for me on 2.055 and 2.056 on windows. What compiler and OS are you
using?
c:\temp>dmd -w test.d
c:\temp>test|more
.\.a.d.un~ 5326
.\.asciidoc_user-guide.txt.un~ 942
(...)
More information about the Digitalmars-d-learn
mailing list