Re: Flush to stdio?

2013-04-01 Thread Kagamin
oops, stdout. int zero=setvbuf(stdout,null,_IONBF,0); assert(zero==0); or stdio.setvbuf(0,_IONBF);

Re: Flush to stdio?

2013-04-01 Thread Kagamin
You can also try to call setvbuf on stdio with _IONBF mode to set it to non-buffering mode.

Re: testsuite: optimization dependent test

2013-04-01 Thread Kagamin
On Friday, 29 March 2013 at 13:24:42 UTC, Iain Buclaw wrote: https://github.com/D-Programming-Language/dmd/pull/1809 lol, put imports after test3.

Re: Flush to stdio?

2013-04-01 Thread Iain Buclaw
On 1 April 2013 19:49, DLearner wrote: > On Monday, 1 April 2013 at 18:36:52 UTC, Iain Buclaw wrote: > >> On 1 April 2013 19:13, Dleaner wrote: >> >> I was using writef("escape string" ~ "Display string") to try to simulate >>> a console, but noticed that the writes are only flushed when a newl

Re: Flush to stdio?

2013-04-01 Thread Iain Buclaw
On 1 April 2013 19:45, Andrej Mitrovic wrote: > On 4/1/13, Iain Buclaw wrote: > > You mean stdout.flush() ? > > Don't forget seat.putDown() too! > Oh, and also forgot about hands.wash(). -- Iain Buclaw *(p < e ? p++ : p) = (c & 0x0f) + '0';

Re: Flush to stdio?

2013-04-01 Thread DLearner
On Monday, 1 April 2013 at 18:36:52 UTC, Iain Buclaw wrote: On 1 April 2013 19:13, Dleaner wrote: I was using writef("escape string" ~ "Display string") to try to simulate a console, but noticed that the writes are only flushed when a newline is present. Is there a 'flush' function that wor

Re: Flush to stdio?

2013-04-01 Thread Andrej Mitrovic
On 4/1/13, Iain Buclaw wrote: > You mean stdout.flush() ? Don't forget seat.putDown() too!

Re: Flush to stdio?

2013-04-01 Thread Iain Buclaw
On 1 April 2013 19:13, Dleaner wrote: > I was using writef("escape string" ~ "Display string") to try to simulate > a console, but noticed that the writes are only flushed when a newline is > present. > > Is there a 'flush' function that works with stdio? > 'flush()' seems unkown to the compiler,

Flush to stdio?

2013-04-01 Thread Dleaner
I was using writef("escape string" ~ "Display string") to try to simulate a console, but noticed that the writes are only flushed when a newline is present. Is there a 'flush' function that works with stdio? 'flush()' seems unkown to the compiler, and 'fflush()' seems to be for files, not for