On Saturday, 26 December 2015 at 19:52:15 UTC, Adam D. Ruppe wrote:
On Saturday, 26 December 2015 at 19:40:59 UTC, Jay Norwood wrote:
Simple VS console app in D.

If you are running inside visual studio, you need to be aware that output will be block buffered, not line buffered, because VS pipes the output making the program think it is talking to another program instead of to an interactive console (well, because it is!)

Add a stdout.flush(); after writing to force it to show immediately. I really think the read functions ought to flush output too because this is such a FAQ. (indeed, my terminal.d does flush output when you request input)

It doesn't make a difference if I run in VS or from a console window. I had also already tried various forms stdout.flush(). It doesn't make a difference ... still requires two extra enters before it outputs the data. I haven't tried it in linux yet.


Reply via email to