From 61086b8e599a3317728b8d5aa04b5d30fa50133f Mon Sep 17 00:00:00 2001 From: Erik Johansson Andersson Date: Sat, 28 Nov 2015 21:21:42 +0100 Subject: [PATCH] flush after printing --- compiler/ccgexprs.nim | 1 + 1 file changed, 1 insertion(+) diff --git a/compiler/ccgexprs.nim b/compiler/ccgexprs.nim index 1a1c1eb6f..51f88d305 100644 --- a/compiler/ccgexprs.nim +++ b/compiler/ccgexprs.nim @@ -959,6 +959,7 @@ proc genEcho(p: BProc, n: PNode) = addf(args, ", $1? ($1)->data:\"nil\"", [rdLoc(a)]) linefmt(p, cpsStmts, "printf($1$2);$n", makeCString(repeat("%s", n.len) & tnl), args) + linefmt(p, cpsStmts, "fflush(stdout);$n") proc gcUsage(n: PNode) = if gSelectedGC == gcNone: message(n.info, warnGcMem, n.renderTree)