From 2f5cfd68298868cabcbc20967aa35bc708d507a8 Mon Sep 17 00:00:00 2001 From: ringabout <43030857+ringabout@users.noreply.github.com> Date: Sat, 20 Jul 2024 11:40:38 +0800 Subject: [PATCH] fixes nim secret not flushing stdout (#23862) related to https://github.com/nim-lang/Nim/pull/19584 On Vscode wsl2 Before: ![image](https://github.com/user-attachments/assets/4bb4f92d-757d-4edf-9dcf-17fcb98f0b60) After ![image](https://github.com/user-attachments/assets/289a113e-c27c-4b76-9d13-725ca28f2828) --- compiler/llstream.nim | 1 + 1 file changed, 1 insertion(+) diff --git a/compiler/llstream.nim b/compiler/llstream.nim index fa223b3739..cc81484830 100644 --- a/compiler/llstream.nim +++ b/compiler/llstream.nim @@ -68,6 +68,7 @@ when not declared(readLineFromStdin): # fallback implementation: proc readLineFromStdin(prompt: string, line: var string): bool = stdout.write(prompt) + stdout.flushFile() result = readLine(stdin, line) if not result: stdout.write("\n")