fix nim secret dots interfering with prompt (#16491)

* fix nim secret dots

* cleanups
This commit is contained in:
Timothee Cour 2020-12-28 03:19:47 -08:00 • committed by GitHub
commit f9a15dbae9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 4 deletions

View file

@ -138,7 +138,8 @@ proc commandInteractive(graph: ModuleGraph) =
var m = graph.makeStdinModule()
incl(m.flags, sfMainModule)
var idgen = IdGenerator(module: m.itemId.module, item: m.itemId.item)
processModule(graph, m, idgen, llStreamOpenStdIn())
let s = llStreamOpenStdIn(onPrompt = proc() = flushDot(graph.config, stderr))
processModule(graph, m, idgen, s)
proc commandScan(cache: IdentCache, config: ConfigRef) =
var f = addFileExt(AbsoluteFile mainCommandArg(config), NimExt)