Fixed order of output in repl and added a proc for opening a custom repl (#10802)
This commit is contained in:
parent
b9f8528db6
commit
92cd07be8b
2 changed files with 25 additions and 3 deletions
|
|
@ -70,10 +70,10 @@ proc llStreamClose*(s: PLLStream) =
|
|||
when not declared(readLineFromStdin):
|
||||
# fallback implementation:
|
||||
proc readLineFromStdin(prompt: string, line: var string): bool =
|
||||
stdout.write(prompt)
|
||||
stderr.write(prompt)
|
||||
result = readLine(stdin, line)
|
||||
if not result:
|
||||
stdout.write("\n")
|
||||
stderr.write("\n")
|
||||
quit(0)
|
||||
|
||||
proc endsWith*(x: string, s: set[char]): bool =
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue