[beginner] Why nothing is printed to stdout ?

2011-10-30 Thread Frédéric Galusik
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); } } /

Re: [beginner] Why nothing is printed to stdout ?

2011-10-30 Thread simendsjo
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)) {

Re: [beginner] Why nothing is printed to stdout ?

2011-10-30 Thread Frédéric Galusik
Le Sun, 30 Oct 2011 12:17:24 +0100, simendsjo a écrit : > 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 > (...) Tested with dmd 2.055 and now 2.056 on Li

Re: [beginner] Why nothing is printed to stdout ?

2011-10-30 Thread Jesse Phillips
On Sun, 30 Oct 2011 10:00:21 +, 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;

Re: [beginner] Why nothing is printed to stdout ?

2011-10-30 Thread Nick Sabalausky
"Frédéric Galusik" wrote in message news:j8j77l$pfv$1...@digitalmars.com... > 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 (D

Re: [beginner] Why nothing is printed to stdout ?

2011-10-30 Thread Mike James
"Nick Sabalausky" wrote in message news:j8kd11$25v1$1...@digitalmars.com... > "Frédéric Galusik" wrote in message > news:j8j77l$pfv$1...@digitalmars.com... >> Hi, >> >> Can someone give me a clue on why nothing is printed to stdout ? >> >> I wish a list of files with their size. >> >> code: >>

Re: [beginner] Why nothing is printed to stdout ?

2011-10-30 Thread Dmitry Olshansky
On 30.10.2011 14: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)) {

Re: [beginner] Why nothing is printed to stdout ?

2011-10-31 Thread Frédéric Galusik
Le Sun, 30 Oct 2011 16:44:20 -0400, Nick Sabalausky a écrit : > "Frédéric Galusik" wrote in message > news:j8j77l$pfv$1...@digitalmars.com... >> 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

Re: [beginner] Why nothing is printed to stdout ?

2011-10-31 Thread Frédéric Galusik
Le Mon, 31 Oct 2011 00:55:58 +0400, Dmitry Olshansky a écrit : > On 30.10.2011 14: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; >> >>

Re: [beginner] Why nothing is printed to stdout ?

2011-10-31 Thread Steven Schveighoffer
On Mon, 31 Oct 2011 06:01:05 -0400, Frédéric Galusik wrote: Le Mon, 31 Oct 2011 00:55:58 +0400, Dmitry Olshansky a écrit : On 30.10.2011 14: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: // i

Re: [beginner] Why nothing is printed to stdout ?

2011-11-01 Thread Kagamin
Steven Schveighoffer Wrote: > Oh I remember doing that too :) Don't feel bad, everyone does this at > least once. I hate that stupid test builtin, nobody ever uses it anymore. > > Note, it's not a command line tool, it's a shell builtin, which is why it > overrides anything in your search p

Re: [beginner] Why nothing is printed to stdout ?

2011-11-01 Thread Jonathan M Davis
On Tuesday, November 01, 2011 04:27 Kagamin wrote: > Steven Schveighoffer Wrote: > > Oh I remember doing that too :) Don't feel bad, everyone does this at > > least once. I hate that stupid test builtin, nobody ever uses it > > anymore. > > > > Note, it's not a command line tool, it's a shell buil

Re: [beginner] Why nothing is printed to stdout ?

2011-11-01 Thread Jude Young
Ew. speak no blasphemy... On Tue, Nov 1, 2011 at 6:27 AM, Kagamin wrote: > Steven Schveighoffer Wrote: > > > Oh I remember doing that too :) Don't feel bad, everyone does this at > > least once. I hate that stupid test builtin, nobody ever uses it > anymore. > > > > Note, it's not a command l

Re: [beginner] Why nothing is printed to stdout ?

2011-11-01 Thread Graham Fawcett
On Tue, 01 Nov 2011 07:27:44 -0400, Kagamin wrote: > Steven Schveighoffer Wrote: > >> Oh I remember doing that too :) Don't feel bad, everyone does this at >> least once. I hate that stupid test builtin, nobody ever uses it >> anymore. >> >> Note, it's not a command line tool, it's a shell bui

Re: [beginner] Why nothing is printed to stdout ?

2011-11-01 Thread Frédéric Galusik
Le Tue, 01 Nov 2011 18:23:52 +, Graham Fawcett a écrit : > On Tue, 01 Nov 2011 07:27:44 -0400, Kagamin wrote: > >> Steven Schveighoffer Wrote: >> >>> Oh I remember doing that too :) Don't feel bad, everyone does this at >>> least once. I hate that stupid test builtin, nobody ever uses it >

Re: [beginner] Why nothing is printed to stdout ?

2011-11-01 Thread Jonathan M Davis
On Tuesday, November 01, 2011 18:23:52 Graham Fawcett wrote: > On Tue, 01 Nov 2011 07:27:44 -0400, Kagamin wrote: > > Steven Schveighoffer Wrote: > >> Oh I remember doing that too :) Don't feel bad, everyone does this at > >> least once. I hate that stupid test builtin, nobody ever uses it > >> a

Re: [beginner] Why nothing is printed to stdout ?

2011-11-01 Thread Graham Fawcett
On Tue, 01 Nov 2011 12:18:02 -0700, Jonathan M Davis wrote: > On Tuesday, November 01, 2011 18:23:52 Graham Fawcett wrote: >> On Tue, 01 Nov 2011 07:27:44 -0400, Kagamin wrote: >> > Steven Schveighoffer Wrote: >> >> Oh I remember doing that too :) Don't feel bad, everyone does this >> >> at least

Re: [beginner] Why nothing is printed to stdout ?

2011-11-02 Thread Steven Schveighoffer
On Tue, 01 Nov 2011 14:23:52 -0400, Graham Fawcett wrote: On Tue, 01 Nov 2011 07:27:44 -0400, Kagamin wrote: Steven Schveighoffer Wrote: Oh I remember doing that too :) Don't feel bad, everyone does this at least once. I hate that stupid test builtin, nobody ever uses it anymore. Note,

Re: [beginner] Why nothing is printed to stdout ?

2011-11-02 Thread Graham Fawcett
On Wed, 02 Nov 2011 07:56:19 -0400, Steven Schveighoffer wrote: > On Tue, 01 Nov 2011 14:23:52 -0400, Graham Fawcett > wrote: > >> On Tue, 01 Nov 2011 07:27:44 -0400, Kagamin wrote: >> >>> Steven Schveighoffer Wrote: >>> Oh I remember doing that too :) Don't feel bad, everyone does this >>

Re: [beginner] Why nothing is printed to stdout ?

2011-11-02 Thread Kagamin
Jonathan M Davis Wrote: > Though if you don't get used to putting ./ in front of the names of binaries > that you're running in the current directory, you're going to have other > problems. The suggestion does fix the occasional screw-up with that > particular > command though. Seems like ./

Re: [beginner] Why nothing is printed to stdout ?

2011-11-02 Thread Nick Sabalausky
"Kagamin" wrote in message news:j8rlig$145l$1...@digitalmars.com... > Jonathan M Davis Wrote: > >> Though if you don't get used to putting ./ in front of the names of >> binaries >> that you're running in the current directory, you're going to have other >> problems. The suggestion does fix the

Re: [beginner] Why nothing is printed to stdout ?

2011-11-02 Thread Nick Sabalausky
"Steven Schveighoffer" wrote in message news:op.v4bh35eaeav7ka@localhost.localdomain... > On Tue, 01 Nov 2011 14:23:52 -0400, Graham Fawcett > wrote: >> >> Too much work! Just put >> >> alias test='./test' >> >> in your .profile, and be happy. :) > > That's a cool trick :) > > However, one is

Re: [beginner] Why nothing is printed to stdout ?

2011-11-03 Thread Kagamin
Nick Sabalausky Wrote: > > Seems like ./ tries to fix some sort of Namespace Pollution Hell when > > virtually every installed program ends up in path. > > It's also a safety/security matter. Imagine: > > $ cat ./ls > #!/bin/sh > rm ~ -rf > > Gee, let's see what's inside this directory...WTF?